refractor(bootstrap): Format with shfmt

This commit is contained in:
js0ny 2025-02-24 00:42:55 +00:00
parent f015467b1b
commit 0ce74497cd
21 changed files with 271 additions and 377 deletions

View file

@ -7,22 +7,20 @@ echo "[INFO] WHEEL = $WHEEL"
echo "[ACTION] Press any key to proceed"
read -n 1
if [ "$WHEEL" -eq 1 ]; then
echo "[INFO] Setting up system-wide zsh configuration"
echo "[ACTION] Elevation required"
test -f "/etc/zsh/zshenv" && sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zsh/zshenv"
test -f "/etc/zshenv" && sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zshenv"
if [ $(uname) = "Darwin" ]; then
sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zshenv"
fi
echo "[INFO] Setting up system-wide zsh configuration"
echo "[ACTION] Elevation required"
test -f "/etc/zsh/zshenv" && sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zsh/zshenv"
test -f "/etc/zshenv" && sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zshenv"
if [ $(uname) = "Darwin" ]; then
sudo cp "$DOTFILES/tools/zsh/global.zshenv" "/etc/zshenv"
fi
else
echo "[INFO] Setting up user zsh configuration"
# A fallback case to set $ZDOTDIR in ~/.zshenv if the user cannot access global zshenv
ln -sf "$DOTFILES/tools/zsh/zshenv" "$HOME/.zshenv"
echo "[INFO] Setting up user zsh configuration"
# A fallback case to set $ZDOTDIR in ~/.zshenv if the user cannot access global zshenv
ln -sf "$DOTFILES/tools/zsh/zshenv" "$HOME/.zshenv"
fi
echo "[INFO] Installing zsh plugins"
test -d $ZDOTDIR/plugins/zsh-autosuggestions || git clone --depth 1 https://github.com/zsh-users/zsh-autosuggestions.git $ZDOTDIR/plugins/zsh-autosuggestions
test -d $ZDOTDIR/plugins/zsh-syntax-highlighting || git clone --depth 1 https://github.com/zsh-users/zsh-syntax-highlighting.git $ZDOTDIR/plugins/zsh-syntax-highlighting