From db1a3e0b532d11eeba6b3c5f5e813ce530da2916 Mon Sep 17 00:00:00 2001 From: Robin Date: Mon, 29 Sep 2025 18:31:35 +0200 Subject: [PATCH] removed kdeconnect because of unnecesserity and added nix home configurations and added ohmyposh for the zsh --- .config/ghostty/config | 1 + .config/hypr/hyprland.conf | 2 +- .config/kdeconnect/certificate.pem | 11 ----- .config/kdeconnect/config | 3 -- .config/kdeconnect/privateKey.pem | 5 -- .config/kdeconnect/trusted_devices | 5 -- .config/nixpkgs/home.nix | 21 +++++++++ .config/ohmyposh/catppuccin.json | 67 +++++++++++++++++++++++++++ .config/ohmyposh/zen.toml | 71 ++++++++++++++++++++++++++++ .config/ohmyposh/zen.toml.bak | 74 ++++++++++++++++++++++++++++++ .gitignore | 1 + .zshrc | 65 ++++++++++---------------- 12 files changed, 259 insertions(+), 67 deletions(-) delete mode 100644 .config/kdeconnect/certificate.pem delete mode 100644 .config/kdeconnect/config delete mode 100644 .config/kdeconnect/privateKey.pem delete mode 100644 .config/kdeconnect/trusted_devices create mode 100644 .config/nixpkgs/home.nix create mode 100644 .config/ohmyposh/catppuccin.json create mode 100644 .config/ohmyposh/zen.toml create mode 100644 .config/ohmyposh/zen.toml.bak diff --git a/.config/ghostty/config b/.config/ghostty/config index af4bd51..5d26641 100644 --- a/.config/ghostty/config +++ b/.config/ghostty/config @@ -48,3 +48,4 @@ theme = catppuccin-latte.conf background-opacity = 0.9 font-size = 23 +font-family = "CaskaydiaCove Nerd Font Mono" diff --git a/.config/hypr/hyprland.conf b/.config/hypr/hyprland.conf index cec9d46..c506772 100644 --- a/.config/hypr/hyprland.conf +++ b/.config/hypr/hyprland.conf @@ -84,7 +84,7 @@ bind = $mainMod, E, exec, nautilus #File explorer bind = $mainMod, V, togglefloating, bind = $mainMod, R, exec, wofi #application launcher -bind = $mainMod SHIFT, R, exec, killall waybar; waybar +bind = $mainMod SHIFT, R, exec, ps aux | grep waybar | grep -v grep | awk '{print $2}' | xargs kill; waybar bind = $mainMod, P, pseudo, # dwindle bind = $mainMod, W, exec, pavucontrol bind = $mainMod, O, togglesplit, # dwindle diff --git a/.config/kdeconnect/certificate.pem b/.config/kdeconnect/certificate.pem deleted file mode 100644 index 5fdd5af..0000000 --- a/.config/kdeconnect/certificate.pem +++ /dev/null @@ -1,11 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIBrDCCAVGgAwIBAgIVAOxtBSXgSE7l52IHYAfjPDEE7IvlMAoGCCqGSM49BAME -MFUxLzAtBgNVBAMMJl9hMWVjNjA2ZF8xODM4XzQ2NjFfOGYzN18wNmEyODQxOTIy -NjNfMQwwCgYDVQQKDANLREUxFDASBgNVBAsMC0tERSBDb25uZWN0MB4XDTIzMTEw -ODExNDUzNloXDTM0MDcyOTExNDUzNlowVTEvMC0GA1UEAwwmX2ExZWM2MDZkXzE4 -MzhfNDY2MV84ZjM3XzA2YTI4NDE5MjI2M18xDDAKBgNVBAoMA0tERTEUMBIGA1UE -CwwLS0RFIENvbm5lY3QwWTATBgcqhkjOPQIBBggqhkjOPQMBBwNCAARY0VGBrFiD -x0z6E0KOn3pbU4XYApFRoKQbj1FJO+KIbEsie72DbKPavGP5elhrZAPhhXU8EzdV -3fhAWvoybC+ZMAoGCCqGSM49BAMEA0kAMEYCIQD/xUqudQv1QWPwLX6XjFpUHi9H -yhT74OqemFRvDM2epgIhAIDfMxEvJqj44mWQD/EADcXizd4/r7xfzl1TX2d/QlaZ ------END CERTIFICATE----- diff --git a/.config/kdeconnect/config b/.config/kdeconnect/config deleted file mode 100644 index 718f3c6..0000000 --- a/.config/kdeconnect/config +++ /dev/null @@ -1,3 +0,0 @@ -[General] -keyAlgorithm=EC -name=robaa diff --git a/.config/kdeconnect/privateKey.pem b/.config/kdeconnect/privateKey.pem deleted file mode 100644 index 16082e8..0000000 --- a/.config/kdeconnect/privateKey.pem +++ /dev/null @@ -1,5 +0,0 @@ ------BEGIN EC PRIVATE KEY----- -MHcCAQEEIMd4iSkIoSHV5VdxcdBAckaeP+DwEn8XlcwHO+aSoo9UoAoGCCqGSM49 -AwEHoUQDQgAEWNFRgaxYg8dM+hNCjp96W1OF2AKRUaCkG49RSTviiGxLInu9g2yj -2rxj+XpYa2QD4YV1PBM3Vd34QFr6MmwvmQ== ------END EC PRIVATE KEY----- diff --git a/.config/kdeconnect/trusted_devices b/.config/kdeconnect/trusted_devices deleted file mode 100644 index 66b581a..0000000 --- a/.config/kdeconnect/trusted_devices +++ /dev/null @@ -1,5 +0,0 @@ -[682ae317_2616_4c3f_9aba_e60d728deb17] -certificate="-----BEGIN CERTIFICATE-----\nMIIBkzCCATmgAwIBAgIBATAKBggqhkjOPQQDBDBTMS0wKwYDVQQDDCQ2ODJhZTMx\nN18yNjE2XzRjM2ZfOWFiYV9lNjBkNzI4ZGViMTcxFDASBgNVBAsMC0tERSBDb25u\nZWN0MQwwCgYDVQQKDANLREUwHhcNMjMxMjA0MjMwMDAwWhcNMzQxMjA0MjMwMDAw\nWjBTMS0wKwYDVQQDDCQ2ODJhZTMxN18yNjE2XzRjM2ZfOWFiYV9lNjBkNzI4ZGVi\nMTcxFDASBgNVBAsMC0tERSBDb25uZWN0MQwwCgYDVQQKDANLREUwWTATBgcqhkjO\nPQIBBggqhkjOPQMBBwNCAASjuADVSsWX8CiEXgJkYdJM8uWqNvyHXIAAiQpZFd27\na0NgykjTNt/5BBFvC/B1XqWqCkiPBTA8/JZPapHmTXtxMAoGCCqGSM49BAMEA0gA\nMEUCIQCtijjl7OlMIySAZcLvXcGXDHRuLlHs8retRJZ5OGxfEQIgaQRPWwgfa97E\nKevPWgNyS9PEw05GxNBa2elcUJsVL3A=\n-----END CERTIFICATE-----\n" -name=Pixel 8a -protocolVersion=8 -type=phone diff --git a/.config/nixpkgs/home.nix b/.config/nixpkgs/home.nix new file mode 100644 index 0000000..fb3afe8 --- /dev/null +++ b/.config/nixpkgs/home.nix @@ -0,0 +1,21 @@ +programs.zsh = { + enable = true; + enableCompletions = true; + autosuggestions.enable = true; + syntaxHighlighting.enable = true; + + shellAliases = { + ll = "ls -l"; + update = "sudo nixos-rebuild switch"; + alias vim="nvim"; + alias cls="clear"; + alias femboy="echo '$USER is a femboy'"; + alias shut="shutdown now"; + alias re="reboot"; + alias ls="exa"; + alias switchhack="fusee-nano ~/Downloads/switchhack/hekate_ctcaer_6.3.0.bin"; + alias ssh_t='(){ ssh $1 -t tmux;}'; + alias sshserver="ssh -i ~/.ssh/GlaServer00 glala@81.21.121.109"; + }; + history.size = 10000; +}; diff --git a/.config/ohmyposh/catppuccin.json b/.config/ohmyposh/catppuccin.json new file mode 100644 index 0000000..e993878 --- /dev/null +++ b/.config/ohmyposh/catppuccin.json @@ -0,0 +1,67 @@ +{ + "$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json", + "palette": { + "os": "#ACB0BE", + "closer": "p:os", + "pink": "#ea76cb", + "lavender": "#7287FD", + "blue": "#1e66f5" + }, + "blocks": [ + { + "alignment": "left", + "segments": [ + { + "foreground": "p:os", + "style": "plain", + "template": "{{.Icon}} ", + "type": "os" + }, + { + "foreground": "p:lavender", + "style": "plain", + "template": "{{ .UserName }} ", + "type": "session" + }, + { + "foreground": "p:pink", + "properties": { + "folder_icon": "..\ue5fe..", + "home_icon": "~", + "style": "agnoster_short" + }, + "style": "plain", + "template": "{{ .Path }} ", + "type": "path" + }, + { + "foreground": "p:lavender", + "properties": { + "branch_icon": "\ue725 ", + "cherry_pick_icon": "\ue29b ", + "commit_icon": "\uf417 ", + "fetch_status": false, + "fetch_upstream_icon": false, + "merge_icon": "\ue727 ", + "no_commits_icon": "\uf0c3 ", + "rebase_icon": "\ue728 ", + "revert_icon": "\uf0e2 ", + "tag_icon": "\uf412 " + }, + "template": "{{ .HEAD }} ", + "style": "plain", + "type": "git" + }, + { + "style": "plain", + "foreground": "p:closer", + "template": "\uf105", + "type": "text" + } + ], + "type": "prompt" + } + ], + "final_space": true, + "version": 3 +} diff --git a/.config/ohmyposh/zen.toml b/.config/ohmyposh/zen.toml new file mode 100644 index 0000000..8f55b9c --- /dev/null +++ b/.config/ohmyposh/zen.toml @@ -0,0 +1,71 @@ +"$schema" = "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json" +final_space = true +version = 3 + +[palette] +os = "#4c4f69" +closer = "p:os" +pink = "#dd7878" +lavender = "#7287FD" +blue = "#209fb5" +green = "#40a02b" + +[[blocks]] +alignment = "left" +type = "prompt" + + [[blocks.segments]] + foreground = "p:os" + style = "plain" + template = "{{.Icon}} " + type = "os" + + [[blocks.segments]] + foreground = "p:lavender" + style = "plain" + template = "{{ .UserName }} " + type = "session" + + [[blocks.segments]] + foreground = "p:pink" + style = "plain" + template = "{{ .Path }}" + type = "path" + [blocks.segments.properties] + style = "full" + home_icon = "~" + + [[blocks.segments]] + foreground = "p:lavender" + template = "{{ .HEAD }} " + style = "plain" + type = "git" + + [blocks.segments.properties] + branch_icon = " " + cherry_pick_icon = " " + commit_icon = " " + fetch_status = false + fetch_upstream_icon = false + merge_icon = " " + no_commits_icon = " " + rebase_icon = " " + revert_icon = " " + tag_icon = " " + +[[blocks]] + type = 'prompt' + alignment = 'left' + newline = true + + [[blocks.segments]] + style = "plain" + foreground = "p:green" + template = "-" + type = "text" + +[transient_prompt] +background = "transparent" +foreground = "p:pink" +template = " - " + diff --git a/.config/ohmyposh/zen.toml.bak b/.config/ohmyposh/zen.toml.bak new file mode 100644 index 0000000..7edb6f0 --- /dev/null +++ b/.config/ohmyposh/zen.toml.bak @@ -0,0 +1,74 @@ +#:schema https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json + +version = 2 +final_space = true +console_title_template = '{{ .Shell }} in {{ .Folder }}' + +[[blocks]] + type = 'prompt' + alignment = 'left' + newline = true + + [[blocks.segments]] + type = 'path' + style = 'plain' + background = 'transparent' + foreground = 'blue' + template = '{{ .Path }}' + + [blocks.segments.properties] + style = 'full' + + [[blocks.segments]] + type = 'git' + style = 'plain' + foreground = 'p:grey' + background = 'transparent' + template = ' {{ .HEAD }}{{ if or (.Working.Changed) (.Staging.Changed) }}*{{ end }} {{ if gt .Behind 0 }}⇣{{ end }}{{ if gt .Ahead 0 }}⇡{{ end }}' + + [blocks.segments.properties] + branch_icon = '' + commit_icon = '@' + fetch_status = true + +[[blocks]] + type = 'rprompt' + overflow = 'hidden' + + [[blocks.segments]] + type = 'executiontime' + style = 'plain' + foreground = 'yellow' + background = 'transparent' + template = '{{ .FormattedMs }}' + + [blocks.segments.properties] + threshold = 5000 + +[[blocks]] + type = 'prompt' + alignment = 'left' + newline = true + + [[blocks.segments]] + type = 'text' + style = 'plain' + foreground_templates = [ + "{{if gt .Code 0}}red{{end}}", + "{{if eq .Code 0}}magenta{{end}}", + ] + background = 'transparent' + template = '❯' + +[transient_prompt] + foreground_templates = [ + "{{if gt .Code 0}}red{{end}}", + "{{if eq .Code 0}}magenta{{end}}", + ] + background = 'transparent' + template = '❯ ' + +[secondary_prompt] + foreground = 'magenta' + background = 'transparent' + template = '❯❯ ' diff --git a/.gitignore b/.gitignore index 71bfb3c..d6c9f24 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ +.config/tmux/plugins .stfolder diff --git a/.zshrc b/.zshrc index 87f7eb4..64d8b98 100644 --- a/.zshrc +++ b/.zshrc @@ -1,36 +1,38 @@ -# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. -# Initialization code that may require console input (password prompts, [y/n] -# confirmations, etc.) must go above this block; everything else may go below. -if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then - source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" -fi ZINIT_HOME="${XDG_DATA_HOME:-${HOME}/.local/share}/zinit/zinit.git" -[ ! -d $ZINIT_HOME ] && mkdir -p "$(dirname $ZINIT_HOME)" -[ ! -d $ZINIT_HOME/.git ] && git clone https://github.com/zdharma-continuum/zinit.git "$ZINIT_HOME" + +if [ ! -d "$ZINIT_HOME" ]; then + mkdir -p "$(dirname $ZINIT_HOME)" + git clone https://github.com/zdharma-continuum/zinit.git "$ZINIT_HOME" +fi source "${ZINIT_HOME}/zinit.zsh" -zinit ice depth=1; zinit light romkatv/powerlevel10k - # add in zsh plugins + zinit light zsh-users/zsh-syntax-highlighting zinit light zsh-users/zsh-completions zinit light zsh-users/zsh-autosuggestions zinit light Aloxaf/fzf-tab +# Add in snippets +zinit snippet OMZL::git.zsh +zinit snippet OMZP::git +zinit snippet OMZP::sudo +zinit snippet OMZP::command-not-found +zinit snippet OMZP::ssh +zinit snippet OMZP::kitty + # Load completions -autoload -U compinit && compinit +autoload -Uz compinit && compinit -C zinit cdreplay -q -# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. -[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh +bindkey -e +bindkey "${key[Up]}" history-search-backward +bindkey "${key[Down]}" history-search-forward -bindkey '^[[A' history-search-backward -bindkey '^[[B' history-search-forward - -#History -HISTSIZE=10000 +# History +HISTSIZE=5000 HISTFILE=~/.zsh_history SAVEHIST=$HISTSIZE HISTDUP=erase @@ -42,19 +44,6 @@ setopt hist_save_no_dups setopt hist_ignore_dups setopt hist_find_no_dups -# Add in snippets -zinit snippet OMZL::git.zsh -zinit snippet OMZP::git -zinit snippet OMZP::sudo -zinit snippet OMZP::archlinux -zinit snippet OMZP::kubectl -zinit snippet OMZP::kubectx -zinit snippet OMZP::command-not-found -zinit snippet OMZP::ssh -zinit snippet OMZP::kitty -zinit snippet OMZP::tldr -zinit snippet OMZP::docker-compose - # Completion styling zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}' zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}" @@ -62,26 +51,18 @@ zstyle ':completion:*' menu no zstyle ':fzf-tab:complete:cd:*' fzf-preview 'ls --color $realpath' zstyle ':fzf-tab:complete:__zoxide_z:*' fzf-preview 'ls --color $realpath' +export EDITOR=nvim # Aliase alias vim="nvim" alias cls="clear" -alias update="yay -Syu --noconfirm" alias femboy="echo '$USER is a femboy'" alias shut="shutdown now" alias re="reboot" -alias dragon-drop="GDK_BACKEND=x11 dragon-drop" alias ls="exa" -export EDITOR=nvim alias switchhack="fusee-nano ~/Downloads/switchhack/hekate_ctcaer_6.3.0.bin" -alias moonpi='ssh 192.168.178.145 "SDL_AUDIODRIVER=alsa moonlight-qt stream -1080 -fps 60 --audio-on-host 192.168.178.25 "BigPicture""' alias ssh_t='(){ ssh $1 -t tmux;}' -alias shutmoonpi='ssh 192.168.178.35 "moonlight-qt quit 192.168.178.25 "BigPicture"; killall moonlight-qt"' alias sshserver="ssh -i ~/.ssh/GlaServer00 glala@81.21.121.109" + eval "$(fzf --zsh)" eval "$(zoxide init --cmd cd zsh)" - -## [Completion] -## Completion scripts setup. Remove the following line to uninstall -[[ -f /home/glala/.dart-cli-completion/zsh-config.zsh ]] && . /home/glala/.dart-cli-completion/zsh-config.zsh || true -## [/Completion] - +eval "$(oh-my-posh init zsh --config ~/.config/ohmyposh/zen.toml)"