From d2a1edf0215cfba1e55bf276b80d7c5034012036 Mon Sep 17 00:00:00 2001 From: coolneng Date: Wed, 1 Feb 2023 03:40:42 +0100 Subject: [PATCH] Switch to Gruvbox as light theme --- kitty/.config/kitty/themes/gruvbox.conf | 33 +++++++++++++++ kitty/.config/kitty/themes/iceberg_light.conf | 40 ------------------- neovim/.config/nvim/init.vim | 2 +- scripts/.local/share/scripts/switch-theme | 17 ++++---- tmux/.tmux.conf | 1 + tmux/.tmux/{nord.conf => statusbar.conf} | 4 +- zathura/.config/zathura/gruvbox.conf | 40 +++++++++++++++++++ zathura/.config/zathura/iceberg_light.conf | 5 --- 8 files changed, 86 insertions(+), 56 deletions(-) create mode 100644 kitty/.config/kitty/themes/gruvbox.conf delete mode 100644 kitty/.config/kitty/themes/iceberg_light.conf rename tmux/.tmux/{nord.conf => statusbar.conf} (96%) create mode 100644 zathura/.config/zathura/gruvbox.conf delete mode 100644 zathura/.config/zathura/iceberg_light.conf diff --git a/kitty/.config/kitty/themes/gruvbox.conf b/kitty/.config/kitty/themes/gruvbox.conf new file mode 100644 index 0000000..716499a --- /dev/null +++ b/kitty/.config/kitty/themes/gruvbox.conf @@ -0,0 +1,33 @@ +## name: Gruvbox Light +## author: Pavel Pertsev +## license: MIT/X11 +## upstream: https://raw.githubusercontent.com/gruvbox-community/gruvbox-contrib/master/kitty/gruvbox-light.conf + + +selection_foreground #3c3836 +selection_background #d65d0e + +background #fbf1c7 +foreground #3c3836 + +color0 #ebdbb2 +color1 #cc241d +color2 #98971a +color3 #d79921 +color4 #458588 +color5 #b16286 +color6 #689d6a +color7 #7c6f64 +color8 #928374 +color9 #9d0006 +color10 #79740e +color11 #b57614 +color12 #076678 +color13 #8f3f71 +color14 #427b58 +color15 #282828 + +cursor #665c54 +cursor_text_color #bdae93 + +url_color #458588 diff --git a/kitty/.config/kitty/themes/iceberg_light.conf b/kitty/.config/kitty/themes/iceberg_light.conf deleted file mode 100644 index 1114685..0000000 --- a/kitty/.config/kitty/themes/iceberg_light.conf +++ /dev/null @@ -1,40 +0,0 @@ -background #e8e9ec -foreground #33374c - -selection_background #d2d4dd -selection_foreground #33374c - -cursor #33374c -cursor_text_color #e8e9ec - -# black -color0 #dcdfe7 -color8 #8389a3 - -# red -color1 #cc517a -color9 #cc3768 - -# green -color2 #668e3d -color10 #598030 - -# yellow/orange -color3 #c57339 -color11 #b6662d - -# blue -color4 #2d539e -color12 #22478e - -# magenta/purple -color5 #7759b4 -color13 #6845ad - -# cyan -color6 #3f83a6 -color14 #327698 - -# white -color7 #33374c -color15 #262a3f \ No newline at end of file diff --git a/neovim/.config/nvim/init.vim b/neovim/.config/nvim/init.vim index 991f956..29cfd7e 100644 --- a/neovim/.config/nvim/init.vim +++ b/neovim/.config/nvim/init.vim @@ -33,7 +33,7 @@ let g:UltiSnipsJumpBackwardTrigger = '' call plug#begin('~/.config/nvim/plugged') Plug 'Raimondi/delimitMate' Plug 'arcticicestudio/nord-vim' -Plug 'habamax/vim-polar' +Plug 'morhetz/gruvbox' Plug 'LnL7/vim-nix' call plug#end() ""Colors diff --git a/scripts/.local/share/scripts/switch-theme b/scripts/.local/share/scripts/switch-theme index fdf4184..aeea530 100755 --- a/scripts/.local/share/scripts/switch-theme +++ b/scripts/.local/share/scripts/switch-theme @@ -1,17 +1,18 @@ #!/bin/sh +LIGHT_THEME="gruvbox" +DARK_THEME="nord" + capitalize() { printf '%s' "$1" | head -c 1 | tr "[:lower:]" "[:upper:]" printf '%s' "$1" | tail -c '+2' } change_theme() { - sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/kitty/kitty.conf - sed -i "s/bg=$1/bg=$2/" ~/.config/nvim/init.vim - sed -i "s/iceberg_$1/iceberg_$2/" ~/.dotfiles/tmux/.tmux.conf - sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/zathura/zathurarc - kitty +kitten themes --reload-in=all "Iceberg $(capitalize "$2")" - tmux source-file ~/.tmux.conf + sed -i "s/$1/$2/" ~/.config/kitty/kitty.conf + sed -i "s/$1/$2/" ~/.config/nvim/init.vim + sed -i "s/$1/$2/" ~/.config/zathura/zathurarc + kitty +kitten themes --reload-in=all "$(capitalize "$2")" nvr --remote-send ":source ~/.config/nvim/init.vim " } @@ -35,10 +36,10 @@ mode=$1 if [ "$mode" = "light" ]; then emacsclient --eval "(load-theme 'doom-solarized-light 'no-confirm)" - change_theme dark light + change_theme "$DARK_THEME" "$LIGHT_THEME" recolor_zathura else emacsclient --eval "(load-theme 'doom-one 'no-confirm)" - change_theme light dark + change_theme "$LIGHT_THEME" "$DARK_THEME" recolor_zathura fi diff --git a/tmux/.tmux.conf b/tmux/.tmux.conf index 4720bb1..f9fcf83 100644 --- a/tmux/.tmux.conf +++ b/tmux/.tmux.conf @@ -78,3 +78,4 @@ set -g mouse on bind -T root WheelUpPane if-shell -F -t = "#{alternate_on}" "send-keys -M" "select-pane -t =; copy-mode -e; send-keys -M" bind -T root WheelDownPane if-shell -F -t = "#{alternate_on}" "send-keys -M" "select-pane -t =; send-keys -M" +source ~/.tmux/statusbar.conf diff --git a/tmux/.tmux/nord.conf b/tmux/.tmux/statusbar.conf similarity index 96% rename from tmux/.tmux/nord.conf rename to tmux/.tmux/statusbar.conf index 41e22f7..99fa9e5 100644 --- a/tmux/.tmux/nord.conf +++ b/tmux/.tmux/statusbar.conf @@ -7,5 +7,5 @@ set -g status-right "" set -g pane-border-style "fg=#2e3244" set -g pane-active-border-style "fg=#454b68" setw -g window-status-style "none,fg=black,bg=brightblack" -setw -g window-status-format "#[fg=black,bg=brightblack] #I #W " -setw -g window-status-current-format "#[fg=black,bg=cyan,bold] #I #W " +setw -g window-status-format "#[fg=black,bg=brightblack] #I #W " +setw -g window-status-current-format "#[fg=black,bg=cyan,bold] #I #W " diff --git a/zathura/.config/zathura/gruvbox.conf b/zathura/.config/zathura/gruvbox.conf new file mode 100644 index 0000000..18c4b70 --- /dev/null +++ b/zathura/.config/zathura/gruvbox.conf @@ -0,0 +1,40 @@ +set notification-error-bg "#fbf1c7" # bg +set notification-error-fg "#9d0006" # bright:red +set notification-warning-bg "#fbf1c7" # bg +set notification-warning-fg "#b57614" # bright:yellow +set notification-bg "#fbf1c7" # bg +set notification-fg "#79740e" # bright:green + +set completion-bg "#d5c4a1" # bg2 +set completion-fg "#3c3836" # fg +set completion-group-bg "#ebdbb2" # bg1 +set completion-group-fg "#928374" # gray +set completion-highlight-bg "#076678" # bright:blue +set completion-highlight-fg "#d5c4a1" # bg2 + +# Define the color in index mode +set index-bg "#d5c4a1" # bg2 +set index-fg "#3c3836" # fg +set index-active-bg "#076678" # bright:blue +set index-active-fg "#d5c4a1" # bg2 + +set inputbar-bg "#fbf1c7" # bg +set inputbar-fg "#3c3836" # fg + +set statusbar-bg "#d5c4a1" # bg2 +set statusbar-fg "#3c3836" # fg + +set highlight-color "#b57614" # bright:yellow +set highlight-active-color "#af3a03" # bright:orange + +set default-bg "#fbf1c7" # bg +set default-fg "#3c3836" # fg +set render-loading true +set render-loading-bg "#fbf1c7" # bg +set render-loading-fg "#3c3836" # fg + +# Recolor book content's color +set recolor-lightcolor "#fbf1c7" # bg +set recolor-darkcolor "#3c3836" # fg +set recolor "true" +# set recolor-keephue true # keep original color diff --git a/zathura/.config/zathura/iceberg_light.conf b/zathura/.config/zathura/iceberg_light.conf deleted file mode 100644 index 2fbdd1e..0000000 --- a/zathura/.config/zathura/iceberg_light.conf +++ /dev/null @@ -1,5 +0,0 @@ -set recolor-lightcolor "#e8e9ec" -set recolor-darkcolor "#33374c" -set completion-bg "#e8e9ec" -set statusbar-bg "#e8e9ec" -set statusbar-fg "#33374c"