You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.2 KiB

4 years ago
4 years ago
4 years ago
4 years ago
  1. #!/bin/zsh
  2. # TODO
  3. # bspwm
  4. # gtk3
  5. # emacs
  6. # firefox
  7. # dunst
  8. # ncmpcpp? uses xresources, but might want customizations
  9. # nvim
  10. #x11
  11. PATH_THEME="$XDG_CONFIG_HOME/X11/colors"
  12. case "$1" in
  13. light)
  14. cp "$PATH_THEME/onehalf-light" "$PATH_THEME/current"
  15. ;;
  16. dark)
  17. cp "$PATH_THEME/onehalf-dark" "$PATH_THEME/current"
  18. ;;
  19. esac
  20. xrdb "$PATH_THEME/current"
  21. # kitty
  22. PATH_THEME="$XDG_CONFIG_HOME/kitty/themes"
  23. case "$1" in
  24. light)
  25. cp "$PATH_THEME/onehalf-light.conf" "$PATH_THEME/current.conf"
  26. ;;
  27. dark)
  28. cp "$PATH_THEME/onehalf-dark.conf" "$PATH_THEME/current.conf"
  29. ;;
  30. esac
  31. kitty @ set-colors --all --configured "$PATH_THEME/current.conf" > /dev/null
  32. tput sgr0
  33. tput op
  34. # zsh
  35. # highlighting needs to be changed
  36. PATH_THEME="$XDG_CONFIG_HOME/zsh"
  37. case "$1" in
  38. light)
  39. cp "$PATH_THEME/theme_light" "$PATH_THEME/theme_current"
  40. ;;
  41. dark)
  42. cp "$PATH_THEME/theme_dark" "$PATH_THEME/theme_current"
  43. ;;
  44. esac
  45. source $PATH_THEME/theme_current
  46. # sourcing not enough to change autosuggestion color
  47. # exec updates current window and newly created,
  48. # but not other currently open terminals
  49. exec zsh