feat(zsh): delete the dependency to oh-my-zsh
This commit is contained in:
@@ -22,9 +22,9 @@ function pj_check() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# check for oh-my-zsh
|
# check for oh-my-zsh
|
||||||
if [[ ! -d $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh ]]; then
|
# if [[ ! -d $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh ]]; then
|
||||||
echo "oh-my-zsh is not installed."
|
# echo "oh-my-zsh is not installed."
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# check for zoxide
|
# check for zoxide
|
||||||
if (( ! $+commands[zoxide] )); then
|
if (( ! $+commands[zoxide] )); then
|
||||||
|
|||||||
@@ -73,20 +73,20 @@ function pj_install_plugins() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# git clone oh-my-zsh
|
# git clone oh-my-zsh
|
||||||
if [ ! -d "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh ]; then
|
# if [ ! -d "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh ]; then
|
||||||
echo "Oh My Zsh is not downloaded. Downloading..."
|
# echo "Oh My Zsh is not downloaded. Downloading..."
|
||||||
# git clone https://github.com/ohmyzsh/ohmyzsh.git "$PATH_OHMYZSH"
|
# # git clone https://github.com/ohmyzsh/ohmyzsh.git "$PATH_OHMYZSH"
|
||||||
git clone https://gitee.com/mirrors/ohmyzsh.git "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
|
# git clone https://gitee.com/mirrors/ohmyzsh.git "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
|
||||||
else
|
# else
|
||||||
cd "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
|
# cd "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
|
||||||
if [ ! -d .git ]; then
|
# if [ ! -d .git ]; then
|
||||||
echo "Oh My Zsh is not a git repository. Please remove $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh and try again."
|
# echo "Oh My Zsh is not a git repository. Please remove $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh and try again."
|
||||||
else
|
# else
|
||||||
echo "Oh My Zsh is already exist. Updating..."
|
# echo "Oh My Zsh is already exist. Updating..."
|
||||||
git pull
|
# git pull
|
||||||
fi
|
# fi
|
||||||
cd -
|
# cd -
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
echo "All plugins are installed/updated. Run 'exec zsh' to apply changes."
|
echo "All plugins are installed/updated. Run 'exec zsh' to apply changes."
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user