diff options
| author | Danilo M. <danix@danix.xyz> | 2026-09-11 17:20:50 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-09-11 17:20:50 +0200 |
| commit | 7b55910a786c7652ac80a576399ebd9f81a8ac72 (patch) | |
| tree | 4adaedb0f0ac5003ecc0e19093a2cb5871b18deb /templates | |
| parent | c7cb9dad4e782ee0ff99773c3607ec3b7792c723 (diff) | |
| download | unified-desktop-theme-7b55910a786c7652ac80a576399ebd9f81a8ac72.tar.gz unified-desktop-theme-7b55910a786c7652ac80a576399ebd9f81a8ac72.zip | |
feat(palette): generate every themed config from one scheme
Colours were written down five times: rofi's palette.rasi, the waybar theme,
the kitty theme, the conky and dunst templates, and a MACCHIATO dict inside
udt-accent. Changing scheme meant finding all five, and they had already
drifted: the active waybar theme was Macchiato while theme.css next to it was
Mocha, and nothing imported the latter.
Now a scheme is two files. palette/<scheme>.conf holds the colours under the
scheme's own names, and palette/roles-<scheme>.conf says what each is for.
palette/roles.conf is one `scheme =` line selecting the pair. bin/udt-palette
renders that into each consumer's syntax and install.sh runs it first.
The role map is per-scheme rather than shared because the palettes are
genuinely different shapes: Nord has no `base`, Dracula no `surface0`, and
forcing Catppuccin's names onto them would have meant either renaming their
colours or inventing values. A role names a palette colour with two optional
modifiers, `name/75` for alpha and `name*50` for brightness. The second exists
because GTK's shade() has no palette name to point at.
Ships macchiato, tokyo-night, nord and dracula. --selftest resolves every role
in every scheme and asserts they define the same set, so a scheme that cannot
satisfy a consumer fails at install rather than when someone switches to it.
Verified against the live configs: all 46 waybar colours resolve identically to
the previously active theme including its alpha() and shade() derivations, the
kitty theme is colour-for-colour identical, and the rofi palette has the same
26 values. Generated files are gitignored; switching scheme and switching back
reproduces the originals.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015gbjA2bmswN8jyPDKzrvqe
Diffstat (limited to 'templates')
| -rw-r--r-- | templates/conky.conf.in | 102 | ||||
| -rw-r--r-- | templates/dunstrc.in | 75 | ||||
| -rw-r--r-- | templates/terminal/kitty-macchiato.conf | 84 | ||||
| -rw-r--r-- | templates/waybar/catppuccin-macchiato.css | 63 |
4 files changed, 177 insertions, 147 deletions
diff --git a/templates/conky.conf.in b/templates/conky.conf.in new file mode 100644 index 0000000..92ad989 --- /dev/null +++ b/templates/conky.conf.in @@ -0,0 +1,102 @@ +conky.config={ + out_to_x = false, + out_to_wayland = true, + alignment='tr', + mpd_host = '172.16.34.5', + mpd_port = 6600, + background=true, + color1='@HEADING@', + color2='@LABEL@', + color3='@RULE@', + color4='@VALUE@', + color5='@HIGHLIGHT@', + color6='@OK@', + pad_percents=0, + cpu_avg_samples=4, + default_color='@BODY@', + default_outline_color='@BODY_OUTLINE@', + default_shade_color='@BODY_SHADE@', + default_bar_height=10, + default_bar_width=500, + double_buffer=true, + draw_borders=false, + draw_graph_borders=false, + draw_outline=false, + draw_shades=false, + font='Inconsolata Nerd Font:style=Regular:size=10', + use_spacer=none, + format_human_readable=true, + short_units=yes, + gap_x=1, + gap_y=0, + minimum_height=1030, + minimum_width=600, + net_avg_samples=2, + no_buffers=true, + override_utf8_locale=true, + own_window=true, + own_window_type='desktop', + own_window_argb_value=225, + own_window_class='Conky', + text_buffer_size=2048, + total_run_times=0, + update_interval=3, + uppercase=false, + use_xft=true, + xftalpha=0, +} + +conky.text=[[ +${color1} ${goto 20}Queen Anne's Revenge ${goto 250}${color5} ${cpugovernor cpu0}${alignr}${color}${cpu cpu0}% +${alignr}${color4}TCTL: ${color}${execi 5 cat $(grep -l '^k10temp$' /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp1_input | awk '{printf "%.0f", $1/1000}'}°c ${color3}| ${color4}TCCD1: ${color}${execi 5 sensors k10temp-pci-00c3 | grep 'Tccd1' | awk '{print $2}' | tr -d '+°C'}°c +${alignr}${color4}NVME: ${color}${execi 5 cat $(grep -l '^nvme$' /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp1_input | awk '{printf "%.0f", $1/1000}'}°c +${goto 50}${cpugraph cpu0 74,500 5e7b7b d8deeb -t} +${goto 30}${color}\#1 ${cpubar cpu1 5,100} ${goto 165}\#5 ${cpubar cpu5 5,100} ${goto 300}\#9 ${cpubar cpu9 5,100} ${goto 440}\#13 ${cpubar cpu13 5,100} +${goto 30}\#2 ${cpubar cpu2 5,100} ${goto 165}\#6 ${cpubar cpu6 5,100} ${goto 300}\#10 ${cpubar cpu10 5,100} ${goto 440}\#14 ${cpubar cpu14 5,100} +${goto 30}\#3 ${cpubar cpu3 5,100} ${goto 165}\#7 ${cpubar cpu7 5,100} ${goto 300}\#11 ${cpubar cpu11 5,100} ${goto 440}\#15 ${cpubar cpu15 5,100} +${goto 30}\#4 ${cpubar cpu4 5,100} ${goto 165}\#8 ${cpubar cpu8 5,100} ${goto 300}\#12 ${cpubar cpu12 5,100} ${goto 440}\#16 ${cpubar cpu16 5,100} +${color3}${hr} + +${color1} ${goto 20}GPU ${color4}Arc B580${color}${alignr}${color4}pkg: ${color1}${execi 5 cat $(grep -l xe /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp2_input | awk '{printf "%.0f", $1/1000}'}°c ${color4}vram: ${color}${execi 5 cat $(grep -l xe /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp3_input | awk '{printf "%.0f", $1/1000}'}°c +${alignr}${color4}fan: ${color}${execi 5 cat $(grep -l xe /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/fan1_input} RPM +${color1} ${goto 20}MoBo ${color4}GigaByte X870 Eagle WiFi 7${color}${alignr}${color}${execi 5 cat $(grep -l '^gigabyte_wmi$' /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp2_input | awk '{printf "%.0f", $1/1000}'}°c / ${execi 5 cat $(grep -l '^gigabyte_wmi$' /sys/class/hwmon/hwmon*/name | head -1 | xargs dirname)/temp3_input | awk '{printf "%.0f", $1/1000}'}°c +${color3}${hr} + +${color1} ${goto 20}Disk +${color4}${goto 50}FREE% | FREE / TOTAL ${color} +${goto 18}${color5} ${color}${fs_free_perc /}% free ${color4}|${color} ${fs_free /} ${color4}/${color} ${fs_size /}${alignr}${fs_bar 10,250 /} +${goto 18}${color6} ${color}${fs_free_perc /home}% free ${color4}|${color} ${fs_free /home} ${color4}/${color} ${fs_size /home}${alignr}${fs_bar 10,250 /home} +${if_mounted /data}${goto 18}${color1} ${color}${fs_free_perc /data}% free ${color4}|${color} ${fs_free /data} ${color4}/${color} ${fs_size /data}${alignr}${fs_bar 10,250 /data}${endif} +${if_mounted /mnt/nfs/Slackware}${goto 18}${color1} ${color}${fs_free_perc /mnt/nfs/Slackware}% free ${color4}|${color} ${fs_free /mnt/nfs/Slackware} ${color4}/${color} ${fs_size /mnt/nfs/Slackware}${alignr}${fs_bar 10,250 /mnt/nfs/Slackware}${endif} +${diskiograph_read 50,245}${alignr}${diskiograph_write 50,245} +${color1}${goto 120}${diskio_read}/s${goto 360}${diskio_write}/s +${color4}${goto 119}read ${goto 360} write${color} +${color1} ${goto 20}Cache ${color5}${execpi 900 du -sh $HOME/.cache 2>/dev/null | cut -f1}${color} +${color4}${goto 60}Folder Name${alignr 60}Size${color} +${execpi 900 du -sh $HOME/.cache/* 2>/dev/null | sort -hr | head -4 | awk '{n=substr($2, index($2, ".cache/")+7); if (length(n)>26) n=substr(n,1,25) "…"; printf "${color6}${goto 60}%s${color1}${alignr 60}%s\n", n, $1}'} +${color3}${hr} + +${color1}${font Inconsolata Nerd Font:style=Regular:pixelsize=13} ${goto 20}Network + ${goto 20}${addr br0}${alignr} ${color6}${execi 300 curl ipinfo.io/ip}${color} +${downspeedgraph br0 50,245}${alignr}${upspeedgraph br0 50,245} +${if_match "${addr br0}"!="No Address"}${goto 20}${color1} ${downspeed br0}k/s${goto 350} ${upspeed br0}k/s${endif} +${color4}${goto 20} download ${goto 360} upload${color} +${color3}${hr} + +${color4} ${color}${goto 20}${exec cat /etc/slackware-version}${alignr} ${uptime} + ${goto 20}${kernel}${alignr} ${exec ls /var/log/packages|wc -l} + ${memperc}% / ${memmax}${alignr}${membar 10,250}${color} +${color3}${hr} + +${color4}${goto 60}Process${alignr 60}PID %CPU %MEM${color} +${color6}${goto 60}${top name 1}${color1}${alignr 60}${top pid 1} ${top cpu 1} ${top mem 1} +${color6}${goto 60}${top name 2}${color1}${alignr 60}${top pid 2} ${top cpu 2} ${top mem 2} +${color6}${goto 60}${top name 3}${color1}${alignr 60}${top pid 3} ${top cpu 3} ${top mem 3} +${color6}${goto 60}${top name 4}${color1}${alignr 60}${top pid 4} ${top cpu 4} ${top mem 4} +${color6}${goto 60}${top name 5}${color1}${alignr 60}${top pid 5} ${top cpu 5} ${top mem 5} +${color3}${hr} + +${color1} ${goto 20}${execi 2 playerctl status 2>/dev/null} · ${color4}${execi 2 playerctl metadata --format "{{artist}}"}${color} +${goto 20}${execi 2 playerctl metadata --format "{{title}} ({{duration(position)}} / {{duration(mpris:length)}})" 2>/dev/null} +${goto 50}${execibar 2 5,500 bash -c "pos=\$(playerctl position 2>/dev/null); len=\$(playerctl metadata mpris:length 2>/dev/null); echo \"scale=6; (\$pos / (\$len / 1000000)) * 100\" | bc | awk '{print int(\$1)}'"} +]] diff --git a/templates/dunstrc.in b/templates/dunstrc.in new file mode 100644 index 0000000..f3a096e --- /dev/null +++ b/templates/dunstrc.in @@ -0,0 +1,75 @@ +# See dunst(5) for all configuration options +[global] + monitor = 1 + follow = none + width = 300 + height = (0, 300) + origin = top-right + offset = (10, 50) + scale = 0 + notification_limit = 0 + progress_bar = true + progress_bar_height = 10 + progress_bar_frame_width = 1 + progress_bar_min_width = 150 + progress_bar_max_width = 300 + indicate_hidden = yes + transparency = 15 + separator_height = 2 + padding = 8 + horizontal_padding = 8 + text_icon_padding = 0 + frame_width = 3 + frame_color = "@ACCENT@" + gap_size = 0 + separator_color = frame + sort = yes + font = Noto Sans 11 + line_height = 0 + markup = full + format = "<b>%a</b>\n<i>%s</i>%p %n\n%b" + alignment = left + vertical_alignment = center + show_age_threshold = 60 + ellipsize = middle + ignore_newline = no + stack_duplicates = true + hide_duplicate_count = false + show_indicators = yes + enable_recursive_icon_lookup = true + icon_theme = MB-Blueberry-Suru-GLOW + icon_position = left + icon_corner_radius = 5 + min_icon_size = 32 + max_icon_size = 128 + icon_path = ~/.local/share/icons/MB-Blueberry-Suru-GLOW/status/48/:/usr/share/icons/MB-Blueberry-Suru-GLOW/devices/48/ + sticky_history = yes + history_length = 20 + dmenu = /usr/bin/rofi -theme ~/.config/rofi/udt/list.rasi -dmenu -p dunst + browser = /usr/bin/xdg-open + always_run_script = true + title = Dunst + class = Dunst + corner_radius = 10 + ignore_dbusclose = false + mouse_left_click = context, close_current + mouse_middle_click = do_action, close_current + mouse_right_click = close_all +# to have a consistent behaviour across releases. +[experimental] + per_monitor_dpi = false +[urgency_low] + background = "@BG_ALT@" + foreground = "@FG_DIM@" + frame_color = "@BORDER@" + timeout = 10 +[urgency_normal] + background = "@BG@" + foreground = "@FG@" + frame_color = "@ACCENT@" + timeout = 10 +[urgency_critical] + background = "@BG@" + foreground = "@FG@" + frame_color = "@CRITICAL@" + timeout = 0 diff --git a/templates/terminal/kitty-macchiato.conf b/templates/terminal/kitty-macchiato.conf deleted file mode 100644 index 92fa1c0..0000000 --- a/templates/terminal/kitty-macchiato.conf +++ /dev/null @@ -1,84 +0,0 @@ -# vim:ft=kitty - -## name: Catppuccin Kitty Macchiato -## author: Catppuccin Org -## license: MIT -## upstream: https://github.com/catppuccin/kitty/blob/main/themes/macchiato.conf -## blurb: Soothing pastel theme for the high-spirited! - - - -# The basic colors -foreground #cad3f5 -background #24273a -selection_foreground #24273a -selection_background #f4dbd6 - -# Cursor colors -cursor #f4dbd6 -cursor_text_color #24273a - -# Scrollbar colors -scrollbar_handle_color #939ab7 -scrollbar_track_color #494d64 - -# URL color when hovering with mouse -url_color #f4dbd6 - -# Kitty window border colors -active_border_color #b7bdf8 -inactive_border_color #6e738d -bell_border_color #eed49f - -# OS Window titlebar colors -wayland_titlebar_color system -macos_titlebar_color system - -# Tab bar colors -active_tab_foreground #181926 -active_tab_background #c6a0f6 -inactive_tab_foreground #cad3f5 -inactive_tab_background #1e2030 -tab_bar_background #181926 - -# Colors for marks (marked text in the terminal) -mark1_foreground #24273a -mark1_background #b7bdf8 -mark2_foreground #24273a -mark2_background #c6a0f6 -mark3_foreground #24273a -mark3_background #7dc4e4 - -# The 16 terminal colors - -# black -color0 #494d64 -color8 #5b6078 - -# red -color1 #ed8796 -color9 #ed8796 - -# green -color2 #a6da95 -color10 #a6da95 - -# yellow -color3 #eed49f -color11 #eed49f - -# blue -color4 #8aadf4 -color12 #8aadf4 - -# magenta -color5 #f5bde6 -color13 #f5bde6 - -# cyan -color6 #8bd5ca -color14 #8bd5ca - -# white -color7 #b8c0e0 -color15 #a5adcb diff --git a/templates/waybar/catppuccin-macchiato.css b/templates/waybar/catppuccin-macchiato.css deleted file mode 100644 index d98b1cc..0000000 --- a/templates/waybar/catppuccin-macchiato.css +++ /dev/null @@ -1,63 +0,0 @@ -/* catppuccin macchiato */ - -@define-color rosewater #f4dbd6; -@define-color flamingo #f0c6c6; -@define-color pink #f5bde6; -@define-color mauve #c6a0f6; -@define-color red #ed8796; -@define-color maroon #ee99a0; -@define-color peach #f5a97f; -@define-color yellow #eed49f; -@define-color green #a6da95; -@define-color teal #8bd5ca; -@define-color sky #91d7e3; -@define-color sapphire #7dc4e4; -@define-color blue #8aadf4; -@define-color lavender #b7bdf8; -@define-color text #cad3f5; -@define-color subtext1 #b8c0e0; -@define-color subtext0 #a5adcb; -@define-color overlay2 #939ab7; -@define-color overlay1 #8087a2; -@define-color overlay0 #6e738d; -@define-color surface2 #5b6078; -@define-color surface1 #494d64; -@define-color surface0 #363a4f; -@define-color base #24273a; -@define-color mantle #1e2030; -@define-color crust #181926; - -/* - br - border - bg - background - fg - foreground -*/ - -/* main colors */ - -@define-color accent @lavender; -@define-color main-br @subtext0; -@define-color main-bg @crust; -@define-color main-fg @text; -@define-color hover-bg @base; -@define-color hover-fg alpha(@main-fg, 0.75); -@define-color outline shade(@main-bg, 0.5); - -/* module colors */ - -@define-color workspaces @mantle; -@define-color temperature @mantle; -@define-color memory @base; -@define-color cpu @surface0; -@define-color time @surface0; -@define-color date @base; -@define-color tray @mantle; -@define-color volume @mantle; -@define-color backlight @base; -@define-color battery @surface0; - -/* state colors */ - -@define-color warning @yellow; -@define-color critical @red; -@define-color charging @green; |
