lupan-set-theme: toggle st theme (note: needs st patched to handle USR1)
This commit is contained in:
@@ -19,6 +19,16 @@ else
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -f ~/.Xresources ]; then
|
||||
if [ "$THEME" = dark ]; then
|
||||
sed -i 's/^#undef THEME_DARK/#define THEME_DARK/' ~/.Xresources
|
||||
elif [ "$THEME" = light ]; then
|
||||
sed -i 's/^#define THEME_DARK/#undef THEME_DARK/' ~/.Xresources
|
||||
fi
|
||||
xrdb -merge ~/.Xresources
|
||||
killall -USR1 st
|
||||
fi
|
||||
|
||||
# Alacritty
|
||||
if [ -f ~/.config/alacritty/alacritty.yml ]; then
|
||||
sed -i "s/^colors: [*].*/colors: *$THEME/" ~/.config/alacritty/alacritty.yml
|
||||
|
||||
Reference in New Issue
Block a user