Merge branch 'main' of ssh://gitea.mmeip.cn:8022/gwbeip/TerminalPolyjuice

This commit is contained in:
2026-04-03 16:15:39 +08:00
3 changed files with 18 additions and 18 deletions

View File

@@ -22,9 +22,9 @@ function pj_check() {
fi
# check for oh-my-zsh
if [[ ! -d $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh ]]; then
echo "oh-my-zsh is not installed."
fi
# if [[ ! -d $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh ]]; then
# echo "oh-my-zsh is not installed."
# fi
# check for zoxide
if (( ! $+commands[zoxide] )); then

View File

@@ -73,20 +73,20 @@ function pj_install_plugins() {
fi
# git clone oh-my-zsh
if [ ! -d "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh ]; then
echo "Oh My Zsh is not downloaded. Downloading..."
# git clone https://github.com/ohmyzsh/ohmyzsh.git "$PATH_OHMYZSH"
git clone https://gitee.com/mirrors/ohmyzsh.git "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
else
cd "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
if [ ! -d .git ]; then
echo "Oh My Zsh is not a git repository. Please remove $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh and try again."
else
echo "Oh My Zsh is already exist. Updating..."
git pull
fi
cd -
fi
# if [ ! -d "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh ]; then
# echo "Oh My Zsh is not downloaded. Downloading..."
# # git clone https://github.com/ohmyzsh/ohmyzsh.git "$PATH_OHMYZSH"
# git clone https://gitee.com/mirrors/ohmyzsh.git "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
# else
# cd "$ZSH_POLYJUICE_PLUGINS_PATH"/ohmyzsh
# if [ ! -d .git ]; then
# echo "Oh My Zsh is not a git repository. Please remove $ZSH_POLYJUICE_PLUGINS_PATH/ohmyzsh and try again."
# else
# echo "Oh My Zsh is already exist. Updating..."
# git pull
# fi
# cd -
# fi
echo "All plugins are installed/updated. Run 'exec zsh' to apply changes."
}

View File

@@ -55,7 +55,7 @@ if [[ -f $ZSH_POLYJUICE_PLUGINS_PATH/zsh-syntax-highlighting/zsh-syntax-highligh
source $ZSH_POLYJUICE_PLUGINS_PATH/zsh-syntax-highlighting/zsh-syntax-highlighting.plugin.zsh
fi
if [[ -f $ZSH_POLYJUICE_PLUGINS_PATH/fzf-tab/fzf-tab.plugin.zsh ]]; then
source $ZSH_POLYJUICE_PLUGINS_PATH/fzf-tab/fzf-tab.plugin.zsh # relies on fzf itself and zsh-autosuggestions plugin
source $ZSH_POLYJUICE_PLUGINS_PATH/fzf-tab/fzf-tab.plugin.zsh # relies on fzf itself and zsh-autocomplete plugin
fi
# using starship as prompt