diff --git a/install.sh b/install.sh index abf9deb..4bbee02 100644 --- a/install.sh +++ b/install.sh @@ -6,6 +6,15 @@ if [ ! -d ~/.oh-my-zsh ]; then sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended fi +# remove Powerlevel10k theme +if [ -n $(sed -n '/Enable Powerlevel10k instant prompt/=' ~/.zshrc) ]; then + sed -i '1,6d' ~/.zshrc +fi +if [ -n $(sed -n '/source ~\/.p10k.zsh/=' ~/.zshrc) ]; then + sed -i -e '/# To customize prompt, run `p10k configure` or edit ~\/.p10k.zsh./d' ~/.zshrc + sed -i -e '/^\[\[ \! -f ~\/.p10k.zsh .*/d' ~/.zshrc +fi + # install starship theme & alias plugin if [ ! -d ~/.oh-my-zsh/custom/plugins/rainbow-alias ]; then mkdir -p ~/.oh-my-zsh/custom/plugins/rainbow-alias/