fixing folder detection
This commit is contained in:
+6
-6
@@ -2,25 +2,25 @@
|
|||||||
cd ~
|
cd ~
|
||||||
|
|
||||||
# check if oh my zsh installed
|
# check if oh my zsh installed
|
||||||
if [ ! -d "~/.oh-my-zsh" ]; then
|
if [ ! -d ~/.oh-my-zsh ]; then
|
||||||
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
|
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# install starship theme & alias plugin
|
# install starship theme & alias plugin
|
||||||
if [ ! -d "~/.oh-my-zsh/custom/plugins/rainbow-alias" ]; then
|
if [ ! -d ~/.oh-my-zsh/custom/plugins/rainbow-alias ]; then
|
||||||
mkdir -p ~/.oh-my-zsh/custom/plugins/rainbow-alias/
|
mkdir -p ~/.oh-my-zsh/custom/plugins/rainbow-alias/
|
||||||
curl -o ~/.oh-my-zsh/custom/plugins/rainbow-alias/rainbow-alias.plugin.zsh https://scm.i-blacknet.de/mkurz/rainbow-zsh-theme/raw/branch/master/rainbow-alias.plugin.zsh
|
curl -o ~/.oh-my-zsh/custom/plugins/rainbow-alias/rainbow-alias.plugin.zsh https://scm.i-blacknet.de/mkurz/rainbow-zsh-theme/raw/branch/master/rainbow-alias.plugin.zsh
|
||||||
fi
|
fi
|
||||||
curl -o ~/.config/starship.toml https://scm.i-blacknet.de/mkurz/starship-theme/raw/branch/main/starship.toml
|
curl -o ~/.config/starship.toml https://scm.i-blacknet.de/mkurz/starship-theme/raw/branch/main/starship.toml
|
||||||
|
|
||||||
# install needfull plugins
|
# install needfull plugins
|
||||||
if [ ! -d "~/.oh-my-zsh/custom/plugins/zsh-autosuggestions" ]; then
|
if [ ! -d ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions ]; then
|
||||||
git clone https://github.com/zsh-users/zsh-autosuggestions.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
|
git clone https://github.com/zsh-users/zsh-autosuggestions.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
|
||||||
fi
|
fi
|
||||||
if [ ! -d "~/.oh-my-zsh/custom/plugins/zsh-history-substring-search" ]; then
|
if [ ! -d ~/.oh-my-zsh/custom/plugins/zsh-history-substring-search ]; then
|
||||||
git clone https://github.com/zsh-users/zsh-history-substring-search ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-history-substring-search
|
git clone https://github.com/zsh-users/zsh-history-substring-search ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-history-substring-search
|
||||||
fi
|
fi
|
||||||
if [ ! -d "~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting" ]; then
|
if [ ! -d ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting ]; then
|
||||||
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
|
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -38,7 +38,7 @@ if [ -z $(sed -n '/zsh-syntax-highlighting/=' ~/.zshrc) ]; then
|
|||||||
sed -i -e 's/\(^plugins=([^)]*\)/\1 zsh-syntax-highlighting/' ~/.zshrc
|
sed -i -e 's/\(^plugins=([^)]*\)/\1 zsh-syntax-highlighting/' ~/.zshrc
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "eval "\""$(starship init zsh)"\"" >> ~/.zshrc
|
echo -e '\neval "$(starship init zsh)"' >> ~/.zshrc
|
||||||
|
|
||||||
echo "Change Shell to zsh when you want!"
|
echo "Change Shell to zsh when you want!"
|
||||||
echo "chsh -s $(which zsh)"
|
echo "chsh -s $(which zsh)"
|
||||||
Reference in New Issue
Block a user