2021-01-07 08:09:41 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if [ -z $1 ]
|
|
|
|
then
|
|
|
|
echo "Missing theme argument"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
|
|
|
theme=$1
|
|
|
|
themedir=$MY_THEMES_DIR/$theme
|
|
|
|
configdir=$MY_CONFIG_DIR
|
|
|
|
|
|
|
|
echo "Setting up $theme theme"
|
|
|
|
# move theme files
|
|
|
|
cp $themedir/colorlist $configdir/Xconfigfiles/colorlist
|
|
|
|
cp $themedir/termitetheme $configdir/termite/termitetheme
|
|
|
|
cp $themedir/dunstcolors $configdir/dunst/dunstcolors
|
|
|
|
cp $themedir/theme.vim $MY_VIM_HOME/theme.vim
|
|
|
|
cp $themedir/fehbg $configdir/other-scripts/fehbg
|
|
|
|
|
2021-01-12 22:18:09 +00:00
|
|
|
rm $configdir/alacritty/colors.yml.bak
|
|
|
|
mv $configdir/alacritty/colors.yml $configdir/alacritty/colors.yml.bak
|
2021-01-17 20:49:31 +00:00
|
|
|
rm $configdir/newsboat/colors.bak
|
|
|
|
mv $configdir/newsboat/colors $configdir/newsboat/colors.bak
|
2021-01-12 22:18:09 +00:00
|
|
|
ln -sT $themedir/alacritty_colors.yml $configdir/alacritty/colors.yml
|
2021-01-13 07:14:33 +00:00
|
|
|
ln -sT $themedir/sway_colors $configdir/sway/conf.d/99_colors_override
|
2021-01-17 20:49:31 +00:00
|
|
|
ln -sT $themedir/newsboatcolors $configdir/newsboat/colors
|
2021-01-12 22:18:09 +00:00
|
|
|
|
2021-01-07 08:09:41 +00:00
|
|
|
FG=black
|
|
|
|
if [[ $theme == *"light"* ]]; then
|
|
|
|
FG=white
|
|
|
|
fi
|
|
|
|
|
|
|
|
echo "PRIMARY_FG=$FG" > ~/.dotfiles/symlinks/zshrc.theme
|
|
|
|
echo "$theme detected as a $FG theme"
|
2021-01-12 22:18:09 +00:00
|
|
|
notify-send "$theme detected as $FG theme" --icon=dialog-information
|