From cd090d0fab1a094216708b01477ef80e8df5c1d8 Mon Sep 17 00:00:00 2001 From: Wryn Wagner Date: Wed, 8 Jan 2020 13:11:56 -0700 Subject: [PATCH] Added kitty color autoconfig and on-the-fly config --- setup | 2 ++ zsh/colors | 17 +++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/setup b/setup index 42dc837..5d70eb7 100755 --- a/setup +++ b/setup @@ -52,3 +52,5 @@ function SYMLINK_CONFIG() { SYMLINK_CONFIG "compton" "compton.conf"; SYMLINK_CONFIG "i3" "config"; +SYMLINK_CONFIG "kitty" "kitty.conf"; +SYMLINK_CONFIG "kitty" "theme.conf"; diff --git a/zsh/colors b/zsh/colors index f411824..80ba038 100644 --- a/zsh/colors +++ b/zsh/colors @@ -24,3 +24,20 @@ PROMPT=$'\n'' %B%F{128}%# %b%f' setopt PROMPT_SUBST PS1="$PREVIOUS_COMMAND_CONDITION $USER $SEPARATOR $DIRECTORY $GIT_BRANCH $PROMPT" #RPROMPT="$(\e[1A) $GIT_BRANCH"; + + +###################################################################################### +# +function kittyChangeTheme () { + [ ! $1 ] && echo no filename given :c && return 1; + [ ! -f "$DOTWRYN/config/colorschemes/kitty/$1" ] \ + && echo colorscheme not supported && return 2; + + rm $DOTWRYN/config/kitty/theme.conf + ln -s "$DOTWRYN/config/colorschemes/kitty/$1" "$DOTWRYN/config/kitty/theme.conf"\ + && echo 'theme changed successfully! (effective on new terminal session)' +} +_kittyChangeTheme () { + compadd $(ls $DOTWRYN/config/colorschemes/kitty) +} +compdef _kittyChangeTheme kittyChangeTheme;