(bash) update

This commit is contained in:
jc 2024-08-09 15:18:42 -04:00
commit b3afcc6f87
No known key found for this signature in database

View file

@ -243,7 +243,7 @@ if [ $TERM_COLOR_MODE == "light" ]; then
fi fi
if [ $USE_TERM == "alacritty" ]; then if [ $USE_TERM == "alacritty" ]; then
theme_link="$HOME/.config/alacritty/theme.toml" theme_link="$HOME/.config/alacritty/theme.toml"
rm -r "$theme_link" rm -rf "$theme_link"
ln "$HOME/.config/alacritty/themes/themes/catppuccin_latte.toml" "$theme_link" ln "$HOME/.config/alacritty/themes/themes/catppuccin_latte.toml" "$theme_link"
fi fi
else else
@ -261,8 +261,6 @@ fi
# source ~/.config/kitty/setup.sh # source ~/.config/kitty/setup.sh
# function to toggle kitty terminal theme # function to toggle kitty terminal theme
toggle_theme() { toggle_theme() {
theme_link="$HOME/.config/alacritty/theme.toml"
rm -r "$theme_link"
if [ "$TERM_COLOR_MODE" == "light" ]; then if [ "$TERM_COLOR_MODE" == "light" ]; then
export TERM_COLOR_MODE=dark export TERM_COLOR_MODE=dark
theme="catppuccin_latte" theme="catppuccin_latte"
@ -270,8 +268,14 @@ toggle_theme() {
export TERM_COLOR_MODE=light export TERM_COLOR_MODE=light
theme="catppuccin_mocha" theme="catppuccin_mocha"
fi fi
# kitten @ set-colors --all "$HOME/.config/kitty/$TERM_COLOR_MODE.conf" if [ $USE_TERM == "kitty" ]; then
ln "$HOME/.config/alacritty/themes/themes/$theme.toml" "$theme_link" kitten @ set-colors --all "$HOME/.config/kitty/$TERM_COLOR_MODE.conf"
fi
if [ $USE_TERM == "alacritty" ]; then
theme_link="$HOME/.config/alacritty/theme.toml"
rm -r "$theme_link"
ln "$HOME/.config/alacritty/themes/themes/$theme.toml" "$theme_link"
fi
} }
type -p curl >/dev/null || echo -e "$WARNING curl is not installed" type -p curl >/dev/null || echo -e "$WARNING curl is not installed"