From ad8c460962bd7fd6ac4374ec73efc090b995bbef Mon Sep 17 00:00:00 2001 From: Gil Portenseigne Date: Thu, 25 Jan 2024 15:54:29 +0100 Subject: [PATCH] Application de ma config zsh, avec l'usage de kube. --- .config/bash/gil_specific.sh | 31 ++++++++++++++++++++++++++----- installSystem.sh | 5 +++-- 2 files changed, 29 insertions(+), 7 deletions(-) diff --git a/.config/bash/gil_specific.sh b/.config/bash/gil_specific.sh index c664421..e5cf6e1 100644 --- a/.config/bash/gil_specific.sh +++ b/.config/bash/gil_specific.sh @@ -1,11 +1,6 @@ export EDITOR=~/.local/bin/nvim.appimage export TERMINAL=/usr/bin/st -source /usr/share/bash-completion/completions/pass -source ~/.config/bash/complete_alias.sh - -complete -F _complete_alias k - export PATH=$PATH:~/.local/bin alias vi="$EDITOR" alias ya="yadm add" @@ -37,3 +32,29 @@ reboot_to_windows () sudo grub-reboot "$windows_title" && sudo reboot } alias windows='reboot_to_windows' + + +##### oh my zsh config overload + +# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes +ZSH_THEME="terminalparty" +zstyle ':omz:update' mode auto # update automatically without asking + +# Uncomment the following line to enable command auto-correction. +ENABLE_CORRECTION="true" +COMPLETION_WAITING_DOTS="true" + +# Uncomment the following line if you want to disable marking untracked files +# under VCS as dirty. This makes repository status check for large repositories +# much, much faster. +DISABLE_UNTRACKED_FILES_DIRTY="true" + +# Which plugins would you like to load? +# Standard plugins can br found in $ZSH/plugins/ +# Custom plugins may be added to $ZSH_CUSTOM/plugins/ +# Example format: plugins=(rails git textmate ruby lighthouse) +# Add wisely, as too many plugins slow down shell startup. +plugins=(git docker kube-ps1 kubectx kubectl) + +source $ZSH/oh-my-zsh.sh +PROMPT='$(kube_ps1)'$PROMPT diff --git a/installSystem.sh b/installSystem.sh index d345940..9eafbe4 100644 --- a/installSystem.sh +++ b/installSystem.sh @@ -6,7 +6,7 @@ groups | grep -q sudo || return # sudo usermod -aG sudo $user # pour passer sudoers, puis reboot sudo apt remove vim-gtk3 vim vim-nox -sudo apt install -y zsh cmake python3-tldextract uuid-runtime webext-browserpass webext-ublock-origin-firefox curl pass python3 ripgrep fonts-firacode fd-find tmux postgresql rsync nextcloud-desktop chromium tig locate htop libx11-dev libxinerama-dev libxft-dev libx11-xcb-dev libxcb-res0-dev arandr make gcc pulsemixer unclutter libnotify-bin ncal dmenu brightnessctl brightness-udev feh autorandr inkscape neomutt isync msmtp lynx notmuch abook urlview pulseaudio-utils mailsync slock bash-completion dunst +sudo apt install -y zsh cmake python3-tldextract uuid-runtime webext-browserpass webext-ublock-origin-firefox curl pass python3 ripgrep fonts-firacode fd-find tmux postgresql rsync nextcloud-desktop tig locate htop libx11-dev libxinerama-dev libxft-dev libx11-xcb-dev libxcb-res0-dev arandr make gcc pulsemixer unclutter libnotify-bin ncal dmenu brightnessctl brightness-udev feh autorandr inkscape neomutt isync msmtp lynx notmuch abook urlview pulseaudio-utils mailsync slock bash-completion dunst kubectx sudo apt autoremove [ ! -f "$HOME/.local/bin/fd" ] && ln -s $(which fdfind) ~/.local/bin/fd @@ -23,7 +23,8 @@ sudo apt autoremove #sudo chsh -s /bin/zsh $USER # Installation config specif bash + aliases -grep -q "gil_specific" "$HOME/.zshrc" && echo "Zshsh configured" || sed -i -e '$asource "$HOME/.config/bash/gil_specific.sh"\' $HOME/.zshrc +sed -i '/source /d' $HOME/.zshrc +grep -q "gil_specific" "$HOME/.zshrc" && echo "Zsh configured" || sed -i -e '$asource "$HOME/.config/bash/gil_specific.sh"\' $HOME/.zshrc # Installation sdkman