From 913b0223fb438b84320e7f78bf0e5a679f12e1fa Mon Sep 17 00:00:00 2001 From: mnussbaum Date: Fri, 2 Mar 2018 12:09:41 -0800 Subject: Build color components separately and combine into default with partials --- templates/bar-colors.mustache | 12 ++++++++++ templates/client-properties.mustache | 8 +++++++ templates/colors-only.mustache | 21 ----------------- templates/colors.mustache | 21 +++++++++++++++++ templates/config.yaml | 11 ++++++++- templates/default.mustache | 44 +++--------------------------------- 6 files changed, 54 insertions(+), 63 deletions(-) create mode 100644 templates/bar-colors.mustache create mode 100644 templates/client-properties.mustache delete mode 100644 templates/colors-only.mustache create mode 100644 templates/colors.mustache (limited to 'templates') diff --git a/templates/bar-colors.mustache b/templates/bar-colors.mustache new file mode 100644 index 0000000..fd5ed89 --- /dev/null +++ b/templates/bar-colors.mustache @@ -0,0 +1,12 @@ +colors { + background $base00 + separator $base01 + statusline $base04 + + # State Border BG Text + focused_workspace $base05 $base0D $base00 + active_workspace $base05 $base03 $base00 + inactive_workspace $base03 $base01 $base05 + urgent_workspace $base08 $base08 $base00 + binding_mode $base00 $base0A $base00 +} diff --git a/templates/client-properties.mustache b/templates/client-properties.mustache new file mode 100644 index 0000000..525b833 --- /dev/null +++ b/templates/client-properties.mustache @@ -0,0 +1,8 @@ +# Basic color configuration using the Base16 variables for windows and borders. +# Property Name Border BG Text Indicator Child Border +client.focused $base05 $base0D $base00 $base0D $base0D +client.focused_inactive $base01 $base01 $base05 $base03 $base01 +client.unfocused $base01 $base00 $base05 $base01 $base01 +client.urgent $base08 $base08 $base00 $base08 $base08 +client.placeholder $base00 $base00 $base05 $base00 $base00 +client.background $base07 diff --git a/templates/colors-only.mustache b/templates/colors-only.mustache deleted file mode 100644 index 5385b19..0000000 --- a/templates/colors-only.mustache +++ /dev/null @@ -1,21 +0,0 @@ -## Base16 {{scheme-name}} -# Author: {{scheme-author}} -# -# You can use these variables anywhere in the i3 configuration file. - -set $base00 #{{base00-hex}} -set $base01 #{{base01-hex}} -set $base02 #{{base02-hex}} -set $base03 #{{base03-hex}} -set $base04 #{{base04-hex}} -set $base05 #{{base05-hex}} -set $base06 #{{base06-hex}} -set $base07 #{{base07-hex}} -set $base08 #{{base08-hex}} -set $base09 #{{base09-hex}} -set $base0A #{{base0A-hex}} -set $base0B #{{base0B-hex}} -set $base0C #{{base0C-hex}} -set $base0D #{{base0D-hex}} -set $base0E #{{base0E-hex}} -set $base0F #{{base0F-hex}} diff --git a/templates/colors.mustache b/templates/colors.mustache new file mode 100644 index 0000000..5385b19 --- /dev/null +++ b/templates/colors.mustache @@ -0,0 +1,21 @@ +## Base16 {{scheme-name}} +# Author: {{scheme-author}} +# +# You can use these variables anywhere in the i3 configuration file. + +set $base00 #{{base00-hex}} +set $base01 #{{base01-hex}} +set $base02 #{{base02-hex}} +set $base03 #{{base03-hex}} +set $base04 #{{base04-hex}} +set $base05 #{{base05-hex}} +set $base06 #{{base06-hex}} +set $base07 #{{base07-hex}} +set $base08 #{{base08-hex}} +set $base09 #{{base09-hex}} +set $base0A #{{base0A-hex}} +set $base0B #{{base0B-hex}} +set $base0C #{{base0C-hex}} +set $base0D #{{base0D-hex}} +set $base0E #{{base0E-hex}} +set $base0F #{{base0F-hex}} diff --git a/templates/config.yaml b/templates/config.yaml index d110e64..a44f88c 100644 --- a/templates/config.yaml +++ b/templates/config.yaml @@ -1,6 +1,15 @@ default: extension: .config output: themes -colors-only: + +bar-colors: + extension: .config + output: bar-colors + +client-properties: + extension: .config + output: client-properties + +colors: extension: .config output: colors diff --git a/templates/default.mustache b/templates/default.mustache index 4ec3823..13932b0 100644 --- a/templates/default.mustache +++ b/templates/default.mustache @@ -1,48 +1,10 @@ -## Base16 {{scheme-name}} -# Author: {{scheme-author}} -# -# You can use these variables anywhere in the i3 configuration file. - -set $base00 #{{base00-hex}} -set $base01 #{{base01-hex}} -set $base02 #{{base02-hex}} -set $base03 #{{base03-hex}} -set $base04 #{{base04-hex}} -set $base05 #{{base05-hex}} -set $base06 #{{base06-hex}} -set $base07 #{{base07-hex}} -set $base08 #{{base08-hex}} -set $base09 #{{base09-hex}} -set $base0A #{{base0A-hex}} -set $base0B #{{base0B-hex}} -set $base0C #{{base0C-hex}} -set $base0D #{{base0D-hex}} -set $base0E #{{base0E-hex}} -set $base0F #{{base0F-hex}} +{{> colors }} # Basic bar configuration using the Base16 variables. bar { status_command i3status - colors { - background $base00 - separator $base01 - statusline $base04 - - # State Border BG Text - focused_workspace $base05 $base0D $base00 - active_workspace $base05 $base03 $base00 - inactive_workspace $base03 $base01 $base05 - urgent_workspace $base08 $base08 $base00 - binding_mode $base00 $base0A $base00 - } + {{> bar-colors }} } -# Basic color configuration using the Base16 variables for windows and borders. -# Property Name Border BG Text Indicator Child Border -client.focused $base05 $base0D $base00 $base0D $base0D -client.focused_inactive $base01 $base01 $base05 $base03 $base01 -client.unfocused $base01 $base00 $base05 $base01 $base01 -client.urgent $base08 $base08 $base00 $base08 $base08 -client.placeholder $base00 $base00 $base05 $base00 $base00 -client.background $base07 +{{> client-properties }} -- cgit