repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

Merge remote-tracking branch 'bugabinga/trunk' into git_remotes_integration

575abd9554eddbfdf08cb741cf880e56d542371b

Oliver Krylow <o.krylow@isp-insoft.de> ·

unsigned

Browse filesCompare with HEAD

Changed files (41)

+2157 / −257 text lines · all files grouped into 32 bars

Diff layout

desktop.symlinks

Modified

+3 / −0 text lines

124124pueue/pueued.service
125125~/.config/systemd/user/pueued.service
127wezterm/systemd/wezterm-mux-server.service
128~/.config/systemd/user/wezterm-mux-server.service
127130psd/psd.conf
128131~/.config/psd/psd.conf

enable_user_services.nu

Modified

+2 / −0 text lines

1212 [mako mako mako.service]
1313 [cliphist cliphist cliphist.service]
1414 [wl-clip-persist wl-clip-persist wl-clip-persist.service]
15 [wezterm-mux-server wezterm-mux-server wezterm-mux-server.service]
1516 [nugu-theme nu nugu-theme.service]
1617 [ironbar ironbar ironbar.service]
18 [ironbar-workspaces python ironbar-workspaces.service]
1921$services | each { | service |

hypr/AGENTS.md

Modified

+2 / −2 text lines

1111 - Mako: `mako/nugu.conf` via `include=~/.config/mako/nugu.conf`
1212 - Hypr Lua: `hypr/generated/nugu.lua`
1313 - Runtime JSON: `hypr/generated/nugu.json`
14- Runtime switcher `hypr/scripts/theme.nu` writes active color fragments under `$XDG_CONFIG_HOME`.
14- Runtime switcher `hypr/scripts/theme.lua` writes active color fragments under `$XDG_CONFIG_HOME`.
1616Hyprtoolkit:
1717- Never rewrite `hyprtoolkit.conf` while Hyprtoolkit apps run.
3737- UI sans: `IBM Plex Sans`; mono/status: `IBM Plex Mono`.
3939Testing:
40- After theme edits: `NUGU_NO_NOTIFY=1 hypr/scripts/theme.nu dark|light`.
40- After theme edits: `NUGU_NO_NOTIFY=1 hypr/scripts/theme.lua dark|light`.
4141- Check `systemctl --user is-active mako.service ironbar.service hyprpaper.service`.
4242- Screenshot dark/light with `grim`; inspect actual rendered colors, not just CSS.

hypr/lib/apps.lua

Modified

+11 / −7 text lines

1local tui = require("scripts.tui_tab")
2
13return {
2 terminal = "wezterm start --always-new-process",
4 terminal = "wezterm connect unix",
35 terminal_class = "wezterm start --always-new-process --class",
46 browser = "firefox",
57 editor = "nvim",
68 launcher = "hyprlauncher",
7 file_manager = "wezterm start --always-new-process --class yazi yazi",
9 file_manager = function() tui.spawn("yazi") end,
10 bluetooth = function() tui.spawn("bluetui") end,
11 wifi = function() tui.spawn("impala") end,
812 lock = "hyprlock",
9 logout = "hyprshutdown",
10 theme_toggle = "nu ~/.config/hypr/scripts/theme.nu toggle",
11 theme_auto = "nu ~/.config/hypr/scripts/theme.nu auto",
13 logout = "hyprshutdown --dry-run",
14 theme_toggle = "lua ~/.config/hypr/scripts/theme.lua toggle",
15 theme_auto = "lua ~/.config/hypr/scripts/theme.lua auto",
1216 clipboard = "bash -lc 'cliphist list | hyprlauncher --dmenu | cliphist decode | wl-copy'",
1317 screenshot_region = "hyprshot -m region -z",
1418 screenshot_window = "hyprshot -m window -z",
1519 screenshot_output = "hyprshot -m output -z",
1620 screenshot_annotate = "hyprshot -m region -z -- satty --filename",
17 binds_help = "nu ~/.config/hypr/scripts/show_binds.nu",
18 clients_help = "nu ~/.config/hypr/scripts/show_clients.nu",
21 binds_help = "lua ~/.config/hypr/scripts/show_binds.lua",
22 clients_help = "lua ~/.config/hypr/scripts/show_clients.lua",

hypr/modules/appearance.lua

Modified

+1 / −1 text lines

6565 },
6767 xwayland = {
68 force_zero_scaling = true,
68 enabled = false,
6969 },
7070})

hypr/modules/binds.lua

Modified

+8 / −5 text lines

33local mod = "SUPER"
55local function bind(key, cmd, description)
6 hl.bind(key, hl.dsp.exec_cmd(cmd), { description = description })
6 local dispatcher = type(cmd) == "function" and cmd or hl.dsp.exec_cmd(cmd)
7 hl.bind(key, dispatcher, { description = description })
78end
910bind(mod .. " + Return", apps.terminal, "terminal: wezterm")
1011bind(mod .. " + Space", apps.launcher, "launcher: hyprlauncher")
1112bind(mod .. " + B", apps.browser, "browser: firefox")
12bind(mod .. " + E", apps.file_manager, "file manager: yazi")
13-- TUI app binds open in an existing WezTerm default mux workspace window as new tabs.
14bind(mod .. " + E", apps.file_manager, "files: yazi")
15bind(mod .. " + N", apps.wifi, "wifi: impala")
16bind(mod .. " + U", apps.bluetooth, "bluetooth: bluetui")
1317hl.bind(mod .. " + Q", hl.dsp.window.close(), { description = "close window" })
1418hl.bind(mod .. " + C", hl.dsp.window.close(), { description = "close window" })
1519bind(mod .. " + V", apps.clipboard, "clipboard history")
4549hl.bind(mod .. " + SHIFT + G", hl.dsp.group.next(), { description = "next group tab" })
4751for _, ws in ipairs(workspaces.list) do
48 local target = "name:" .. ws.name
49 hl.bind(mod .. " + " .. ws.key, hl.dsp.focus({ workspace = target }), { description = "workspace " .. ws.name })
50 hl.bind(mod .. " + SHIFT + " .. ws.key, hl.dsp.window.move({ workspace = target }), { description = "move to " .. ws.name })
52 hl.bind(mod .. " + " .. ws.key, hl.dsp.focus({ workspace = ws.id }), { description = "workspace " .. ws.name })
53 hl.bind(mod .. " + SHIFT + " .. ws.key, hl.dsp.window.move({ workspace = ws.id }), { description = "move to " .. ws.name })
5154end
5356hl.bind(mod .. " + S", hl.dsp.workspace.toggle_special("scratch"), { description = "toggle scratch" })

hypr/modules/input.lua

Modified

+2 / −1 text lines

99 repeat_delay = 600,
1010 follow_mouse = 1,
1111 sensitivity = 0,
12 accel_profile = "flat",
12 accel_profile = "adaptive",
13 natural_scroll = true,
1314 touchpad = {
1415 natural_scroll = true,
1516 disable_while_typing = true,

hypr/modules/rules.lua

Modified

+4 / −17 text lines

77 suppress_event = "maximize",
88})
10hl.window_rule({
11 name = "fix-xwayland-drags",
12 match = {
13 class = "^$",
14 title = "^$",
15 xwayland = true,
16 float = true,
17 fullscreen = false,
18 pin = false,
19 },
20 no_focus = true,
21})
23hl.window_rule({ match = { class = "^(firefox|org.mozilla.firefox)$" }, workspace = "name:web" })
10hl.window_rule({ match = { class = "^(firefox|org.mozilla.firefox)$" }, workspace = "1" })
2411hl.window_rule({ match = { class = "^(firefox|org.mozilla.firefox)$" }, opacity = "0.98 0.96" })
26hl.window_rule({ match = { class = "^(wezterm|org.wezfurlong.wezterm)$" }, workspace = "name:term" })
27hl.window_rule({ match = { class = "^yazi$" }, workspace = "name:term" })
13hl.window_rule({ match = { class = "^(wezterm|org.wezfurlong.wezterm)$" }, workspace = "3" })
14hl.window_rule({ match = { class = "^yazi$" }, workspace = "3" })
29hl.window_rule({ match = { class = "^(mpv|com.github.celluloid_player.Celluloid)$" }, workspace = "name:media" })
16hl.window_rule({ match = { class = "^(mpv|com.github.celluloid_player.Celluloid)$" }, workspace = "5" })
3017hl.window_rule({ match = { class = "^(mpv|com.github.celluloid_player.Celluloid)$" }, immediate = true })
3219hl.window_rule({ match = { class = "^(pavucontrol|blueman-manager|nm-connection-editor)$" }, float = true, center = true })

hypr/modules/workspaces.lua

Modified

+8 / −9 text lines

11local M = {}
33M.list = {
4 { key = "1", name = "web" },
5 { key = "2", name = "code" },
6 { key = "3", name = "term" },
7 { key = "4", name = "chat" },
8 { key = "5", name = "media" },
9 { key = "9", name = "misc" },
10 { key = "0", name = "scratch" },
4 { key = "1", id = "1", name = "web" },
5 { key = "2", id = "2", name = "code" },
6 { key = "3", id = "3", name = "term" },
7 { key = "4", id = "4", name = "chat" },
8 { key = "5", id = "5", name = "media" },
9 { key = "9", id = "9", name = "misc" },
1312for _, ws in ipairs(M.list) do
14 hl.workspace_rule({ workspace = "name:" .. ws.name, monitor = "LVDS-1" })
13 hl.workspace_rule({ workspace = ws.id, monitor = "LVDS-1" })
1514end
17hl.workspace_rule({ workspace = "name:web", default = true })
16hl.workspace_rule({ workspace = "1", default = true })
1817hl.workspace_rule({ workspace = "special:scratch", on_created_empty = "wezterm start --always-new-process" })
1918hl.workspace_rule({ workspace = "w[tv1]s[false]", gaps_out = 0, gaps_in = 0 })
2019hl.workspace_rule({ workspace = "f[1]s[false]", gaps_out = 0, gaps_in = 0 })

hypr/scripts/common.lua

Added
new file mode 100644

+37 / −0 text lines

1local M = {}
2
3function M.trim(value)
4 return (value or ""):gsub("^%s+", ""):gsub("%s+$", "")
5end
6
7function M.shell_quote(value)
8 value = tostring(value)
9 return "'" .. value:gsub("'", "'\\''") .. "'"
10end
12function M.read_command(command)
13 local pipe = io.popen(command .. " 2>/dev/null")
14 if not pipe then return "" end
15 local output = pipe:read("*a") or ""
16 pipe:close()
17 return output
18end
20function M.choose(lines)
21 if #lines == 0 then return nil end
23 local path = os.tmpname()
24 local file = assert(io.open(path, "w"))
25 for _, line in ipairs(lines) do
26 file:write(line, "\n")
27 end
28 file:close()
30 local selected = M.trim(M.read_command("hyprlauncher --dmenu < " .. M.shell_quote(path)))
31 os.remove(path)
33 if selected == "" then return nil end
34 return selected
35end
37return M

hypr/scripts/cycle_clients.lua

Added
new file mode 100644

+73 / −0 text lines

1#!/usr/bin/env lua
2
3local source = debug.getinfo(1, "S").source:gsub("^@", "")
4local script_dir = source:match("(.+)/[^/]+$") or "."
5local hypr_dir = script_dir:match("(.+)/[^/]+$") or "."
6package.path = hypr_dir .. "/?.lua;" .. hypr_dir .. "/?/init.lua;" .. package.path
7
8local common = require("scripts.common")
9
10local function focus(address)
11 if not address:match("^0x") then address = "0x" .. address end
12 local expr = "hl.dispatch(hl.dsp.focus({ window = " .. string.format("%q", "address:" .. address) .. " }))"
13 os.execute("hyprctl -q eval " .. common.shell_quote(expr))
14end
16local function parse_active()
17 return common.read_command("hyprctl activewindow"):match("^Window%s+(%S+)%s+%-%>")
18end
20local function parse_clients()
21 local clients = {}
22 local current
24 for line in common.read_command("hyprctl clients"):gmatch("[^\n]+") do
25 local address, title = line:match("^Window%s+(%S+)%s+%-%>%s+(.+):$")
26 if address then
27 current = { address = address, title = title, class = "", workspace = 0, mapped = true, hidden = false }
28 clients[#clients + 1] = current
29 elseif current then
30 local key, value = line:match("^%s*([%w_]+):%s*(.*)$")
31 if key == "class" then
32 current.class = value
33 elseif key == "workspace" then
34 current.workspace = tonumber(value:match("^(%-?%d+)")) or 0
35 elseif key == "mapped" then
36 current.mapped = value == "1"
37 elseif key == "hidden" then
38 current.hidden = value == "1"
39 end
40 end
41 end
43 local filtered = {}
44 for _, client in ipairs(clients) do
45 if client.mapped and not client.hidden then filtered[#filtered + 1] = client end
46 end
48 table.sort(filtered, function(a, b)
49 if a.workspace ~= b.workspace then return a.workspace < b.workspace end
50 if a.class ~= b.class then return a.class < b.class end
51 if a.title ~= b.title then return a.title < b.title end
52 return a.address < b.address
53 end)
55 return filtered
56end
58local direction = arg[1] == "prev" and -1 or 1
59local clients = parse_clients()
60if #clients < 2 then os.exit(0) end
62local active = parse_active()
63local index = 1
65for i, client in ipairs(clients) do
66 if client.address == active then
67 index = i
68 break
69 end
70end
72local next_index = ((index - 1 + direction) % #clients) + 1
73focus(clients[next_index].address)

hypr/scripts/show_binds.lua

Added
new file mode 100644

+77 / −0 text lines

1#!/usr/bin/env lua
2
3local source = debug.getinfo(1, "S").source:gsub("^@", "")
4local script_dir = source:match("(.+)/[^/]+$") or "."
5local hypr_dir = script_dir:match("(.+)/[^/]+$") or "."
6package.path = hypr_dir .. "/?.lua;" .. hypr_dir .. "/?/init.lua;" .. package.path
7
8local common = require("scripts.common")
9
10local modifier_bits = {
11 { bit = 64, name = "SUPER" },
12 { bit = 1, name = "SHIFT" },
13 { bit = 4, name = "CTRL" },
14 { bit = 8, name = "ALT" },
15}
17local function has_bit(value, bit)
18 return value % (bit * 2) >= bit
19end
21local function mods(mask)
22 local out = {}
23 for _, mod in ipairs(modifier_bits) do
24 if has_bit(mask, mod.bit) then out[#out + 1] = mod.name end
25 end
26 if #out == 0 then return "None" end
27 return table.concat(out, "+")
28end
30local function format_key(key)
31 if key:match("^mouse:") then return key:gsub("^mouse:", "MOUSE_") end
32 return key:upper()
33end
35local binds = {}
36local current
38for line in common.read_command("hyprctl binds"):gmatch("[^\n]+") do
39 if line:match("^bind") then
40 current = { modmask = 0, key = "?", dispatcher = "", arg = "", description = "" }
41 table.insert(binds, current)
42 elseif current then
43 local key, value = line:match("^%s*([%w_]+):%s*(.*)$")
44 if key == "modmask" then
45 current.modmask = tonumber(value) or 0
46 elseif key == "key" then
47 current.key = value
48 elseif key == "dispatcher" then
49 current.dispatcher = value
50 elseif key == "arg" then
51 current.arg = value
52 elseif key == "description" then
53 current.description = value
54 end
55 end
56end
58local labels = {}
59local by_label = {}
61for _, bind in ipairs(binds) do
62 local label = string.format("%s + %s -> %s", mods(bind.modmask), format_key(bind.key), bind.description ~= "" and bind.description or bind.dispatcher)
63 labels[#labels + 1] = label
64 by_label[label] = bind
65end
67local selected = common.choose(labels)
68if not selected then os.exit(0) end
70local bind = by_label[selected]
71if not bind then os.exit(1) end
73if bind.dispatcher == "exec" and bind.arg ~= "" then
74 os.execute(bind.arg .. " &")
75elseif bind.dispatcher ~= "" and bind.dispatcher ~= "__lua" then
76 os.execute("hyprctl dispatch " .. common.shell_quote(bind.dispatcher) .. " " .. common.shell_quote(bind.arg))
77end

hypr/scripts/show_binds.nu

Deleted
deleted file mode 100644

+0 / −54 text lines

1# Function to parse modmask into readable modifier names
2def parse_modmask [modmask: int] {
3 let modifiers = [
4 { mask: 64, name: "SUPER" },
5 { mask: 1, name: "SHIFT" },
6 { mask: 4, name: "CTRL" },
7 { mask: 8, name: "ALT" }
8 ]
9 let active_mods = $modifiers | where { |mod| ($modmask | bits and $mod.mask) != 0 } | get name
10 if ($active_mods | is-empty) { "None" } else { $active_mods | str join "+" }
11}
13# Function to format key for display
14def format_key [key: string, mouse: bool] {
15 if $mouse {
16 $key | str replace "mouse:" "MOUSE_"
17 } else {
18 $key | str upcase
19 }
20}
22# Main function to process binds and show fuzzel menu
23def main [] {
24 # Get binds from hyprctl
25 let binds = (hyprctl binds -j | from json)
27 # Parse binds into a formatted list for fuzzel
28 let formatted_binds = $binds | each { |bind|
29 let mods = (parse_modmask $bind.modmask)
30 let key = (format_key $bind.key $bind.mouse)
31 let display = $"($mods) + ($key) -> ($bind.dispatcher): ($bind.arg)"
32 { display: $display, arg: $bind.arg, dispatcher: $bind.dispatcher }
33 }
35 # Create a temporary file for fuzzel
36 let temp_file = (mktemp -t hypr_binds.XXXXXX | str trim)
37 $formatted_binds | each { |b| $b.display } | str join "\n" | save -f $temp_file
39 # Show fuzzel menu and get selection
40 let selection = (cat $temp_file | fuzzel --dmenu --prompt "Keybindings: " | str trim)
41 rm $temp_file
43 # Find the selected binding and execute its arg
44 if ($selection | is-not-empty) {
45 let selected_bind = ($formatted_binds | where display == $selection | first)
46 if ($selected_bind | is-not-empty) {
47 if $selected_bind.dispatcher == "exec" {
48 run-external ($selected_bind.arg | split row ' ')
49 } else {
50 hyprctl dispatch $selected_bind.dispatcher $selected_bind.arg
51 }
52 }
53 }
54}

hypr/scripts/show_clients.lua

Added
new file mode 100644

+48 / −0 text lines

1#!/usr/bin/env lua
2
3local source = debug.getinfo(1, "S").source:gsub("^@", "")
4local script_dir = source:match("(.+)/[^/]+$") or "."
5local hypr_dir = script_dir:match("(.+)/[^/]+$") or "."
6package.path = hypr_dir .. "/?.lua;" .. hypr_dir .. "/?/init.lua;" .. package.path
7
8local common = require("scripts.common")
9
10local clients = {}
11local current
13for line in common.read_command("hyprctl clients"):gmatch("[^\n]+") do
14 local address, title = line:match("^Window%s+(%S+)%s+%-%>%s+(.+):$")
15 if address then
16 current = { address = address, title = title, class = "?", workspace = "?" }
17 table.insert(clients, current)
18 elseif current then
19 local key, value = line:match("^%s*([%w_]+):%s*(.*)$")
20 if key == "class" then
21 current.class = value
22 elseif key == "workspace" then
23 current.workspace = value:match("%((.-)%)") or value:match("^(%S+)") or "?"
24 end
25 end
26end
28local labels = {}
29local by_label = {}
31for _, client in ipairs(clients) do
32 local label = string.format("%s: %s (%s)", client.class, client.title, client.workspace)
33 labels[#labels + 1] = label
34 by_label[label] = client
35end
37local selected = common.choose(labels)
38if not selected then os.exit(0) end
40local client = by_label[selected]
41if not client then os.exit(1) end
43local address = client.address
44if not address:match("^0x") then address = "0x" .. address end
46local target = "address:" .. address
47local expr = "hl.dispatch(hl.dsp.focus({ window = " .. string.format("%q", target) .. " }))"
48os.execute("hyprctl -q eval " .. common.shell_quote(expr))

hypr/scripts/show_clients.nu

Deleted
deleted file mode 100644

+0 / −25 text lines

1# Fetch and parse hyprctl clients JSON
2let clients = (hyprctl clients -j | from json)
3
4# Format clients for fuzzel: "class: title (workspace)"
5let formatted = ($clients | each { |client|
6 $"($client.class): ($client.title) \(($client.workspace.name)\)"
7} | str join "\n")
8
9# Pipe formatted list to fuzzel and get selected item
10let selected = ($formatted | fuzzel --dmenu --prompt "Select window: " | str trim)
12# Exit if no selection
13if ($selected | is-empty) {
14 exit 0
15}
17# Find the index of the selected item
18let selected_index = ($formatted | split row "\n" | enumerate | where item == $selected | get 0.index)
20# Get the address of the selected client
21let address = ($clients | get $selected_index | get address)
23# Focus the selected window
24hyprctl -q dispatch focuswindow address:($address)
25hyprctl -q dispatch alterzorder top

hypr/scripts/theme.lua

Added
new file mode 100644

+212 / −0 text lines

1#!/usr/bin/env lua
2
3local source = debug.getinfo(1, "S").source:gsub("^@", "")
4local script_dir = source:match("(.+)/[^/]+$") or "."
5local hypr_dir = script_dir:match("(.+)/[^/]+$") or "."
6package.path = hypr_dir .. "/?.lua;" .. hypr_dir .. "/?/init.lua;" .. package.path
7
8local nugu = require("generated.nugu")
9
10local function trim(value)
11 return (value or ""):gsub("^%s+", ""):gsub("%s+$", "")
12end
14local function shell_quote(value)
15 value = tostring(value)
16 return "'" .. value:gsub("'", "'\\''") .. "'"
17end
19local function run(command)
20 os.execute(command .. " >/dev/null 2>&1")
21end
23local function mkdir(path)
24 run("mkdir -p " .. shell_quote(path))
25end
27local function read_file(path)
28 local file = io.open(path, "r")
29 if not file then return nil end
30 local data = file:read("*a")
31 file:close()
32 return data
33end
35local function write_file(path, content)
36 local file = assert(io.open(path, "w"))
37 file:write(content)
38 file:close()
39end
41local home = assert(os.getenv("HOME"), "HOME unset")
42local config_home = os.getenv("XDG_CONFIG_HOME") or home .. "/.config"
43local cache_dir = home .. "/.cache/nugu"
44local mode_file = cache_dir .. "/mode"
45local auto_file = cache_dir .. "/auto"
47local function active_mode()
48 local mode = trim(read_file(mode_file))
49 if mode == "light" then return "light" end
50 return "dark"
51end
53local function auto_mode()
54 local hour = tonumber(os.date("%H")) or 0
55 if hour >= 7 and hour < 19 then return "light" end
56 return "dark"
57end
59local function auto_enabled()
60 local value = read_file(auto_file)
61 return value == nil or trim(value) ~= "0"
62end
64local function set_auto(enabled)
65 mkdir(cache_dir)
66 write_file(auto_file, enabled and "1" or "0")
67end
69local function write_desktop_color_scheme(mode)
70 local scheme = mode == "dark" and "prefer-dark" or "prefer-light"
71 run("gsettings set org.gnome.desktop.interface color-scheme " .. shell_quote(scheme))
72end
74local function write_mako(p)
75 local dir = config_home .. "/mako"
76 mkdir(dir)
77 write_file(dir .. "/nugu.conf", string.format([[# Generated by hypr/scripts/theme.lua from Nugu palette.
78background-color=%see
79text-color=%sff
80border-color=%sff
81progress-color=over %sff
83[urgency=low]
84background-color=%se6
85text-color=%sff
86border-color=%sff
87progress-color=over %sff
89[urgency=normal]
90border-color=%sff
91progress-color=over %sff
93[urgency=critical]
94background-color=%sff
95text-color=%sff
96border-color=%sff
97progress-color=over %sff
99[summary~="[Ee]rror|[Ff]ailed|[Ff]ailure|[Cc]rash"]
100border-color=%sff
101progress-color=over %sff
103[summary~="[Ww]arn|[Ww]arning"]
104border-color=%sff
105progress-color=over %sff
107[summary~="[Ii]nfo|[Nn]otice"]
108border-color=%sff
109progress-color=over %sff
110]],
111 p.ui.backdrop, p.ui.normal, p.ui.accent, p.ui.focus,
112 p.content.backdrop, p.content.minor, p.ui.unfocus, p.content.minor,
113 p.ui.accent, p.ui.focus,
114 p.ui.backdrop, p.ui.important_global, p.error, p.error,
115 p.error, p.error,
116 p.warning, p.warning,
117 p.info, p.info))
118end
120local function write_ironbar(p)
121 local dir = config_home .. "/ironbar"
122 mkdir(dir)
123 write_file(dir .. "/nugu.css", string.format([[/* Generated by hypr/scripts/theme.lua from Nugu palette. */
124:root {
125 --bg: %s;
126 --bg-transparent: %see;
127 --surface: %s;
128 --fg: %s;
129 --accent: %s;
130 --focus: %s;
131 --on-focus: %s;
132 --muted: %s;
133 --unfocus: %s;
134 --error: %s;
135 --warning: %s;
136 --info: %s;
137 --debug: %s;
138 --border: %s;
139}
140]],
141 p.ui.backdrop,
142 p.ui.backdrop,
143 p.ui.minor,
144 p.ui.normal,
145 p.ui.accent,
146 p.ui.focus,
147 p.content.backdrop,
148 p.ui.minor,
149 p.ui.unfocus,
150 p.error,
151 p.warning,
152 p.info,
153 p.debug,
154 p.ui.accent))
155end
157local function apply_mode(mode)
158 mkdir(cache_dir)
159 write_file(mode_file, mode)
161 local p = assert(nugu.get(mode), "unknown mode: " .. tostring(mode))
162 write_desktop_color_scheme(mode)
163 write_mako(p)
164 write_ironbar(p)
166 run("hyprctl hyprpaper wallpaper " .. shell_quote(",~/.config/hypr/wallpapers/nugu-" .. mode .. ".png"))
167 run("hyprctl reload")
168 if os.getenv("NUGU_NO_RESTART_MAKO") ~= "1" then
169 run("systemctl --user restart mako.service")
170 end
171 run("systemctl --user restart ironbar.service")
172 if os.getenv("NUGU_NO_NOTIFY") ~= "1" then
173 run("notify-send --expire-time 1500 nugu " .. shell_quote(mode .. " mode"))
174 end
175end
177local function next_mode()
178 return active_mode() == "dark" and "light" or "dark"
179end
181local function watch()
182 while true do
183 if auto_enabled() then
184 local target = auto_mode()
185 if target ~= active_mode() then apply_mode(target) end
186 end
187 os.execute("sleep 300")
188 end
189end
191local mode = arg[1] or "toggle"
193if mode == "dark" or mode == "light" or mode == "toggle" then
194 set_auto(false)
195elseif mode == "auto" then
196 set_auto(true)
197end
199if mode == "dark" or mode == "light" then
200 apply_mode(mode)
201elseif mode == "toggle" then
202 apply_mode(next_mode())
203elseif mode == "auto" then
204 apply_mode(auto_mode())
205elseif mode == "current" then
206 apply_mode(active_mode())
207elseif mode == "watch" then
208 watch()
209else
210 io.stderr:write("mode must be dark|light|toggle|auto|current|watch\n")
211 os.exit(1)
212end

hypr/scripts/tui_tab.lua

Added
new file mode 100644

+36 / −0 text lines

1local M = {}
2
3local function shell_quote(value)
4 value = tostring(value)
5 return "'" .. value:gsub("'", "'\\''") .. "'"
6end
7
8local function trim(value)
9 return (value or ""):gsub("^%s+", ""):gsub("%s+$", "")
10end
12local function run(command)
13 local pipe = io.popen(command .. " 2>/dev/null")
14 if not pipe then return nil end
16 local output = pipe:read("*a")
17 pipe:close()
19 return trim(output)
20end
22function M.spawn(...)
23 local args = { ... }
24 if #args == 0 then return end
26 for i, arg in ipairs(args) do
27 args[i] = shell_quote(arg)
28 end
30 local pane_id = run("wezterm cli --prefer-mux spawn -- " .. table.concat(args, " "))
31 if pane_id and pane_id:match("^%d+$") then
32 hl.exec_cmd("wezterm cli --prefer-mux activate-pane --pane-id " .. shell_quote(pane_id))
33 end
34end
36return M

hypr/systemd/ironbar-workspaces.service

Added
new file mode 100644

+13 / −0 text lines

1[Unit]
2Description=Instant Ironbar workspace state
3After=graphical-session.target ironbar.service
4PartOf=graphical-session.target ironbar.service
5
6[Service]
7ExecStart=%h/.config/ironbar/scripts/workspaces-watch.py
8Restart=on-failure
9RestartSec=1
10Slice=session.slice
12[Install]
13WantedBy=graphical-session.target

hypr/systemd/ironbar.service

Modified

+1 / −0 text lines

55Wants=nugu-theme.service
77[Service]
8Environment=GSK_RENDERER=cairo
89ExecStart=/usr/bin/ironbar
910Restart=on-failure
1011RestartSec=2

hypr/systemd/mako.service

Modified

+1 / −1 text lines

66[Service]
77Environment=NUGU_NO_RESTART_MAKO=1
88Environment=NUGU_NO_NOTIFY=1
9ExecStartPre=/usr/bin/nu %h/.config/hypr/scripts/theme.nu current
9ExecStartPre=/usr/bin/lua %h/.config/hypr/scripts/theme.lua current
1010ExecStart=/usr/bin/mako --config %h/.config/mako/config
1111Restart=on-failure
1212RestartSec=2

hypr/systemd/nugu-theme.service

Modified

+1 / −1 text lines

55Wants=hyprpaper.service
77[Service]
8ExecStart=/usr/bin/nu %h/.config/hypr/scripts/theme.nu watch
8ExecStart=/usr/bin/lua %h/.config/hypr/scripts/theme.lua watch
99Restart=on-failure
1010RestartSec=10

ironbar/PLAN.md

Added
new file mode 100644

+715 / −0 text lines

1# Ironbar rework plan
2
3Goal: rebuild the bar incrementally, one widget/behavior at a time, with Nugu colors, consistent clicks, and verification after each step.
4
5Workflow rule:
6
71. Propose exact minimal change.
82. Experiment safely when behavior is unknown.
93. Apply focused changes.
104. Verify live with config validation, service state, logs, screenshots, and interaction tests.
115. Remove superfluous widgets/CSS/scripts.
13Originally: stop after each step for discussion.
14Current standing goal: continue autonomously to completion while preserving brutal verification.
16Order rule: start with Bluetooth as requested, then proceed roughly easiest → hardest.
18## Current status
20Done/live:
22- Bluetooth stack installed/running: `bluez`, `bluez-utils`, `bluetooth.service` active.
23- `bluetui` installed and preferred as Bluetooth manager.
24- Ironbar Bluetooth widget is status-only; builtin popup disabled because GTK switch popup looked bad.
25- Bluetooth left/middle click opens `bluetui` through shared Hypr Lua TUI launcher.
26- Ironbar icon theme switched to installed `Adwaita`.
27- Ironbar `popup_autohide = true` globally.
28- WezTerm mux service added under `wezterm/systemd/wezterm-mux-server.service`, enabled and active.
29- WezTerm config attaches GUI to Unix mux (`connect unix`) and status shows `MUX` for mux domain.
30- Hypr `SUPER+Enter` opens `wezterm connect unix`.
31- Hypr TUI app binds:
32 - `SUPER+E` → `yazi`
33 - `SUPER+N` → `impala`
34 - `SUPER+U` → `bluetui`
35- TUI launcher activates the newly spawned WezTerm pane/tab.
36- XWayland disabled; obsolete XWayland drag workaround removed.
37- Mouse accel switched to adaptive; natural scroll enabled.
39Known unresolved:
41- No hard blocker.
42- Physical wheel/trackpad scroll over the volume module remains unverified because `wdotool scroll` does not trigger Ironbar layer-shell scroll events here.
43- Existing visible WezTerm local-domain sessions may need manual migration/closure; no seamless transfer to mux known.
45## Current live audit
47- Repo clean, ahead of origin; Ironbar commits are local.
48- Running services verified active: `ironbar.service`, `ironbar-workspaces.service`, `mako.service`, `hyprpaper.service`, `pipewire-pulse.socket`, system `upower.service`, system `bluetooth.service`.
49- Resource usage after settling: `ironbar` about 1.3% CPU / 77M RSS; `workspaces-watch.py` 0.0% CPU / 15M RSS.
50- Regions use Ironbar `start` / `center` / `end` boxes:
51 - start: custom workspace switcher, clipboard, bindmode
52 - center: music, clock
53 - end: Mako status, WiFi, Bluetooth, tray, CPU, volume, brightness, battery, inhibit, power
54- Polling/wakeups:
55 - Mako status script: 5000ms, shell + `makoctl list | grep`
56 - WiFi status script: 30000ms, shell + `iwctl station wlan0 show`
57 - sys_info CPU: interval 2
58 - workspace state: Hypr socket2 event watcher, 10s idle refresh, no label polling
59- Scroll handlers:
60 - volume: `wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 2%+` / `wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%-`, `smooth_scroll_speed = 1.0`
61 - brightness: builtin systemd backlight backend, `smooth_scroll_speed = 0.5`
62- Hardcoded color grep reports only generated `ironbar/nugu.css`; `style.css` uses semantic Nugu vars.
63- Known broken/unproven widget behavior: physical volume scroll only. Slider drag and the configured scroll commands are verified.
65## Checked facts
67- Installed Ironbar: `0.19.0`.
68- `ironbar --print-schema` exposes needed modules:
69 - `battery`, `bindmode`, `bluetooth`, `brightness`, `clipboard`, `clock`, `custom`, `focused`, `inhibit`, `launcher`, `music`, `notifications`, `script`, `sys_info`, `tray`, `volume`, `workspaces`.
70- WiFi stack: `iwd` + systemd-networkd.
71 - `iwd.service`: active.
72 - `NetworkManager`: not installed.
73 - Ironbar `network_manager` module is wrong unless we intentionally switch network stacks.
74- Notifications: Mako currently.
75 - Ironbar `notifications` module requires SwayNC.
76 - SwayNC would replace/compete with Mako, so defer.
77- `hyprshutdown` installed; keybind uses `--dry-run`.
78- Music config must use `player_type = "mpris"`, not `playerctl`.
79- Builtin Ironbar workspaces dispatch legacy Hypr syntax; custom switcher is used for Lua-dispatcher compatibility.
80- Workspace highlighting is event-driven via Hypr socket2 + Ironbar vars; no polling labels.
82## Upstream feature note
84From Ironbar compiling wiki/features:
86- Default build enables all features.
87- Custom builds can disable defaults and enable selected features.
88- Must enable at least one config feature.
89- If custom-building for this setup:
91```text
92cli,config+json,workspaces+hyprland,focused,launcher,music+mpris,sys_info,script,custom,tray,volume,battery,bluetooth,brightness,bindmode,inhibit,clipboard,clock,notifications
93```
95Notes:
97- `cli` implies `ipc`.
98- `network_manager` omitted while using `iwd`.
99- `notifications` only useful if switching to SwayNC.
101## Preferences / launch policy
103- Work one thing at a time: propose → experiment → change → verify.
104- Prefer awesome fast TUIs when they exist (`bluetui`, `impala`, `btm`, `wiremix`, `yazi`, etc.).
105- Prefer mux-backed WezTerm tabs for TUI apps over standalone terminal windows.
106- Prefer implementation logic in Lua over shell snippets; shell command strings are acceptable only at process boundary.
107- Prefer `require(...)` modules over `dofile(...)` in normal config and shared helpers.
108- Shared TUI launch logic lives in Hypr Lua: `hypr/scripts/tui_tab.lua`.
109- Hypr binds call it via `require("scripts.tui_tab")`; Ironbar actions bridge through `hyprctl eval 'require("scripts.tui_tab").spawn(...)'` so both use the same implementation.
110- TUI launcher should spawn into WezTerm mux and activate the new pane/tab.
111- Keep app-specific service/config files in app dirs when possible, e.g. WezTerm systemd unit under `wezterm/systemd/`.
112- Avoid fighting ugly GTK popups when a better TUI exists; use Ironbar as status/launcher if builtin popup is poor.
114## Package/dependency report
116Already installed:
118- `ironbar`
119- `hyprshutdown`
120- `playerctl`
121- `iwd`
122- `brightnessctl`
123- `bluez`
124- `bluez-utils`
125- `bluetui`
126- `impala`
127- `wezterm-nightly-bin`
128- `upower`
129- `pipewire-pulse`
131No longer planned:
133```sh
134sudo pacman -S pavucontrol swaync networkmanager
135```
137Reasons:
139- `wiremix` replaces `pavucontrol` for audio.
140- Mako stays; SwayNC would replace/compete with it.
141- WiFi stack stays `iwd` + systemd-networkd; no NetworkManager.
143Optional only if requested later:
145```sh
146sudo pacman -S resources
147```
149Avoid unless intentionally switching network stack:
151```sh
152sudo pacman -S networkmanager
153```
155## Verification loop for every step
1571. Edit only one widget/behavior.
1582. Validate:
160 ```sh
161 ironbar --validate-config -c ~/.config/ironbar/config.json -t ~/.config/ironbar/style.css
162 ```
1643. Restart:
166 ```sh
167 systemctl --user restart ironbar.service
168 ```
1704. Inspect:
172 ```sh
173 systemctl --user status ironbar.service --no-pager
174 journalctl --user -u ironbar.service -n 80 --no-pager
175 ```
1775. Screenshot / visual check.
1786. Discuss before next step.
180## Click convention
182- Left: popup or primary action.
183- Right: toggle/mute/secondary action.
184- Middle: open full external tool/TUI.
185- Scroll: adjust continuous value.
186- Tooltip: document behavior.
188## WezTerm mux policy
190- WezTerm GUI should attach to Unix mux by default:
191 - `cfg.unix_domains = { { name = "unix", no_serve_automatically = true } }`
192 - `cfg.default_gui_startup_args = { "connect", "unix" }`
193- Mux server is systemd-managed:
194 - `wezterm/systemd/wezterm-mux-server.service`
195- WezTerm status should make mux visible:
196 - domain `unix` renders as `MUX`.
197- Hypr terminal bind should explicitly use mux:
198 - `wezterm connect unix`
199- TUI app launcher should:
200 1. spawn into mux with `wezterm cli --prefer-mux spawn -- ...`
201 2. capture pane id in Lua
202 3. activate pane with `wezterm cli --prefer-mux activate-pane --pane-id ...`
203- Existing non-mux GUI sessions cannot be seamlessly transferred into mux; recreate/close manually.
205## Nugu styling rules
207- Generated colors stay in `ironbar/nugu.css`.
208- Layout/behavior stay in `ironbar/config.json` + `ironbar/style.css`.
209- Use vars:
210 - normal fg: `--fg`
211 - muted/empty: `--muted` / `--unfocus`
212 - active bg: `--focus`, fg `--on-focus`
213 - hover/accent bg: `--accent`, fg `--on-focus`
214 - error: `--error`
216## Ordered implementation steps
218### Step 1 — Bluetooth — done
220Why first: explicit request.
222Implemented:
224- `bluez` + `bluez-utils` installed by user; `bluetooth.service` active.
225- `bluetui` installed and preferred.
226- Ironbar builtin `bluetooth` module used only for bar status.
227- Builtin Bluetooth popup disabled; GTK switch popup looked bad even after CSS work.
228- Left/middle click opens `bluetui` through shared Hypr Lua TUI launcher:
229 - `hyprctl eval 'require("scripts.tui_tab").spawn("bluetui")'`
230- Bar label uses fixed semantic Bluetooth battery icon, not dynamic percentage icon:
231 - `󰥈 {device_battery_percent}%`
232- `icon_theme` switched from missing `Papirus` to installed `Adwaita`; broken device image fixed.
234Verified:
236- Ironbar config validates.
237- Ironbar restarts and stays active.
238- Popup autohide works globally.
239- Bluetooth status visible; clicks open `bluetui`.
241Follow-up if wanted:
243- Tune bar label length/format.
244- Add notification if Bluetooth disconnected/low battery.
246### Step 2 — baseline validation + obvious fixes
248Difficulty: very easy.
250Scope:
252- Fix music `player_type`: `playerctl` → `mpris`.
253- Add `name`/`class` only where needed for CSS targeting.
254- No layout rework.
256Verify:
258- Config validates.
259- Ironbar starts cleanly.
261### Step 3 — tray
263Difficulty: very easy.
265Goal:
267- Keep tray widget.
268- Improve popover padding/colors if needed.
270Verify:
272- Existing tray icons render.
273- Menus/popovers readable.
275### Step 4 — clock/calendar colors
277Difficulty: easy.
279Goal:
281- Fix hard-to-read calendar popup.
283Scope:
285- CSS only.
286- Explicit GTK calendar selectors:
287 - `.popup-clock calendar`
288 - `.popup-clock calendar header`
289 - `.popup-clock calendar grid label.day-name`
290 - `.popup-clock calendar grid label.day-number`
291 - `.popup-clock calendar grid label.other-month`
292 - `.popup-clock calendar grid label.today`
293 - `.popup-clock calendar grid label:selected`
295Verify:
297- Popup readable in dark + light.
298- Today/current/other-month/day-name colors use Nugu vars.
300### Step 5 — clipboard
302Difficulty: easy.
304Goal:
306- Keep clipboard widget and make behavior explicit.
308Proposed behavior:
310- Left: popup/list.
311- Middle: optional external launcher later.
312- Right: do **not** clear history unless confirmed.
314Verify:
316- Popup readable.
317- Selection/paste still works.
319### Step 6 — volume — done
321Goal:
323- Make volume behavior consistent.
325Implemented:
327- Builtin `volume` module.
328- Scroll adjusts PipeWire output volume.
329- Right click mutes output.
330- Middle click opens `wiremix` through shared Hypr Lua TUI launcher.
331- Sources hidden on bar to reduce clutter.
333Verified:
335- `pipewire-pulse.socket` active.
336- Ironbar logs show volume client connected, no `PAErr(-1)`.
337- `wiremix` spawned into WezTerm mux tab and activated.
338- Popup/device picker colors fixed for dark+light Nugu.
339- Slider drag verified with `wdotool`: volume changed from 55% to 7%, then restored to 55% and unmuted.
340- Scroll actions are configured as oneshot scripts and `smooth_scroll_speed = 1.0` is explicit for wheel/trackpad input.
341- The exact scroll commands were executed manually: 55% → 57% → 55%.
342- `wdotool scroll` does not trigger Ironbar layer-shell scroll events in this live setup, so physical scroll remains the remaining manual check.
344### Step 7 — battery — done
346Difficulty: easy.
348Goal:
350- Add/keep robust battery widget.
352Implementation:
354- Builtin `battery` module.
355- Show icon + percent.
356- Style low/critical/charging states using Nugu semantic colors.
358Verified:
360- Hidden on machines without `BAT*` via `show_if`.
361- Shows X230 battery percentage.
362- `upower` active.
363- Warning/critical states styled with Nugu semantic colors.
365### Step 8 — brightness — done
367Difficulty: easy-medium.
369Goal:
371- Add brightness widget.
373Implementation:
375- Builtin `brightness` module.
376- Use `systemd`/`backlight` backend.
378Implemented:
380- Builtin brightness module with `systemd`/`intel_backlight` backend.
381- Scroll adjusts brightness through Ironbar backend.
382- Rejected custom `brightnessctl` script experiment because direct set failed without permission.
384Verified:
386- Detects `intel_backlight`.
387- Brightness visible/readable in screenshots.
388- No config/service errors.
390Known issue (scroll does not change brightness):
392- `ironbar.service` runs under the user manager, so the process is in a sessionless scope. Ironbar's `systemd` brightness backend calls `org.freedesktop.login1` `SetBrightness`, which is rejected with `org.freedesktop.login1.NotYourDevice: Session is not in foreground, refusing.`
393- Root cause is session ownership, not config. The Ironbar config is already correct (`mode.type = systemd`, `smooth_scroll_speed = 0.5`); changing it cannot fix this. The fix is host-side, requires root, and the agent cannot apply it.
395Note on `udev` `uaccess`:
397- Rejected for this host: the seat's `ActiveSession` is the greeter (Type=wayland, Class=greeter) and the user session is `Idle=yes`. udev `uaccess` hands the device to the session that owns the seat, not the user session ironbar runs in. Live test: after installing `ACTION=="add", SUBSYSTEM=="backlight", TAG+="uaccess"`, `SetBrightness` still returned `NotYourDevice`. Rule was removed. Skip on this seat layout, or also reconfigure seat ownership.
399Note on polkit `login1.set-brightness`:
401- `NotYourDevice` is raised by `logind` **before** polkit is consulted, so the polkit rule cannot fix it on this seat layout. Staged at `polkit/10-brightness.rules` for completeness; install only after the seat is reconfigured so a real user session owns the foreground.
403Arch wiki ([Backlight](https://wiki.archlinux.org/title/Backlight)) recommended fix: udev `RUN+=` to chgrp/chmod the sysfs file, plus the `video` group. sysfs `brightness` is a `DEVICE_ATTR_RW` whose mode is hardcoded `0644`; udev `GROUP=` / `MODE=` keys do **not** apply to sysfs. The rule must include `KERNEL==` to avoid a `RUN+=` flood on every brightness change.
405 ```sh
406 # udev/backlight.rules
407 ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/usr/bin/chgrp video /sys/class/backlight/intel_backlight/brightness"
408 ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/usr/bin/chmod g+w /sys/class/backlight/intel_backlight/brightness"
409 ```
411 ```sh
412 doas install -m 0644 /home/oli/Workspace/dotfiles/udev/backlight.rules /etc/udev/rules.d/backlight.rules
413 doas udevadm control --reload
414 doas udevadm trigger --subsystem-match=backlight --action=add
415 doas usermod -aG video oli # log out / log in (or `newgrp video` for current shell)
416 ```
418 After that, logind `SetBrightness` from the user session still works through the builtin `systemd` backend; sysfs is also directly writable by members of `video` for any helper that bypasses logind (e.g. `brightnessctl` from inside the user session).
420### Step 9 — bindmode
422Difficulty: easy-medium.
424Goal:
426- Show Hyprland submap/bindmode only when active.
428Implementation:
430- Builtin `bindmode` module.
432Verify:
434- Hidden during normal use.
435- Appears/disappears correctly if a Hypr submap is active.
437### Step 10 — inhibit — done
439Difficulty: medium.
441Goal:
443- Add sleep/lock inhibition toggle.
445Implementation:
447- Builtin `inhibit` module.
449Proposed behavior:
451- Left: toggle selected duration.
452- Right: cycle duration.
453- Format off/on clearly.
455Verified:
457- Toggle visible/readable.
458- Duration visible in screenshot.
459- No Ironbar errors.
461### Step 11 — cute cat widget — skipped/removed
463Reason:
465- Cute but superfluous under the current goal.
466- Removed after screenshot showed the right/center area was already dense.
468Verified:
470- Bar validates/restarts without it.
471- Center media has more room.
473### Step 12 — media/player controls — done
475Difficulty: medium.
477Goal:
479- Make media useful and compact.
481Implementation:
483- Builtin `music` module with MPRIS.
484- Format: status icon + truncated title/artist.
485- Popup: album art + controls.
487Implemented:
489- Builtin `music` module with MPRIS.
490- Compact title/artist format with truncation.
491- No extra scroll action; avoid accidental media changes.
493Verified:
495- Firefox/MPRIS player detected.
496- Title visible and compact at 1366px.
497- Popup styled by Nugu CSS.
499### Step 13 — system monitors
501Difficulty: medium.
503Goal:
505- Add compact system monitor row.
507Implementation:
509- Builtin `sys_info` module.
511Candidate labels:
513- CPU percent.
514- RAM percent.
515- Temperature.
516- Disk root percent.
517- Network up/down.
519Implemented:
521- Compact CPU label via builtin `sys_info`.
522- Left/middle opens `btm` through shared Hypr Lua TUI launcher.
524Useful install:
526```sh
527sudo pacman -S bottom
528```
530Optional GUI:
532```sh
533sudo pacman -S resources
534```
536Verify:
538- Values update at sane intervals.
539- Compact enough for 1366px.
540- No excessive CPU wakeups.
542### Step 14 — power menu
544Difficulty: medium-hard.
546Goal:
548- Polish power menu using installed `hyprshutdown`.
550Implementation:
552- `custom` module popup.
554Candidate buttons:
556- poweroff: `hyprshutdown --post-cmd "systemctl poweroff"`
557- reboot: `hyprshutdown --post-cmd "systemctl reboot"`
558- logout: `hyprshutdown`
559- suspend: `loginctl lock-session && systemctl suspend`
560- lock: `hyprlock`
561- Popup order puts destructive actions far left and safe lock nearest the right-side opener, avoiding accidental shutdown/reboot from a second click at the trigger position.
563Verify:
565- Popup opens.
566- Lock/suspend/logout work.
567- Do not test reboot/poweroff without explicit confirmation.
569### Step 15 — notifications — done
571Decision:
573- Keep Mako.
574- Do not install SwayNC; it would replace/compete with Mako.
575- Ironbar builtin `notifications` module remains unused.
577Implemented:
579- Custom Mako indicator script:
580 - empty: `󰂚`
581 - active notifications: `󰂞 N`
582- Left click: `makoctl restore`.
583- Right click: `makoctl dismiss --all`.
585Verified:
587- Mako service active.
588- Count visible/readable in screenshots.
589- Dismissing all notifications via Mako works.
590- No SwayNC dependency.
592### Step 16 — WiFi / network — done
594Decision:
596- Keep `iwd` + systemd-networkd.
597- Do not install/use NetworkManager.
599Implemented:
601- Custom script module reads `iwctl station wlan0 show`.
602- Connected state is icon-only to reduce clutter.
603- Disconnected state shows `󰖪 off`.
604- Left/middle click opens `impala` through shared Hypr Lua TUI launcher.
606Verified:
608- `iwd.service` active.
609- `networkctl status wlan0` routable/online.
610- WiFi icon visible/readable.
611- No NetworkManager dependency.
613### Step 17 — workspaces — done
615Goal:
617- Show fixed workspace favorites.
618- Logical order:
619 - `1 web`
620 - `2 code`
621 - `3 term`
622 - `4 chat`
623 - `5 media`
624 - `9 misc`
625- Empty favorites remain visible.
626- Active/occupied/empty states readable.
627- Click focuses correct workspace.
629Problem found:
631- Builtin Ironbar `workspaces` sends legacy `hyprctl dispatch workspace N`.
632- Hyprland Lua dispatcher rejects that syntax:
633 - `error: [string "return hl.dispatch(workspace 1)"]:1: ')' expected near '1'`
635Implemented:
637- Migrated Hypr workspace rules/binds/window rules to numeric IDs.
638- Replaced builtin Ironbar workspaces with a custom workspace switcher.
639- Each button uses Lua dispatcher syntax:
640 - `hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = "N" }))'`
641- Replaced old polling `ironbar/scripts/workspace-label.lua` with `ironbar/scripts/workspaces-watch.py`.
642- Watcher listens to Hypr socket2 and writes Ironbar vars (`#ws1`, `#ws2`, ...), making highlight update immediately on switch.
643- Watcher uses direct Hypr Unix socket IPC for state reads and only writes changed Ironbar vars.
644- Watcher caches the Hypr socket directory and Nugu CSS vars, avoiding repeated `hyprctl instances` subprocesses and repeated CSS file reads on every workspace event.
645- Added `hypr/systemd/ironbar-workspaces.service`, symlink manifest entry, and service enable recipe.
646- `ironbar-workspaces.service` is `PartOf=ironbar.service` so bar restarts immediately refresh workspace vars.
647- Removed unused builtin `.workspaces` CSS.
648- Removed launcher underline styling after screenshot showed it clashed with the active workspace/focused launcher pills.
649- Increased system-module spacing slightly; verified clock/power still fit on 1366px.
650- Removed unused `.notifications` CSS and normalized `.sysinfo` spacing.
651- Removed normal `scratch` workspace from the bar; special scratch remains on `SUPER+S`.
653Verified:
655- Hypr reload ok; no config errors.
656- Existing named `web`/`term` windows moved to numeric `1`/`3`.
657- All six icons visible; no tofu/question mark glyphs.
658- Empty workspace active-state update verified 0.2s after click.
659- Service active and low overhead: `ironbar` ~1.8% CPU shortly after restart, watcher ~0.2% CPU / 6.6M RSS on X230.
660- Clicks verified via `wdotool`:
661 - workspace `1` focuses `id=1`
662 - empty workspace `2` focuses `id=2`
663 - workspace `3` focuses `id=3`
664- Ironbar logs contain no workspace dispatch errors after custom switcher.
666## Suggested final bar layout
668Start:
6701. workspaces
6712. clipboard
6723. bindmode
674Removed:
676- focused window module; active app/title was redundant and made the left side noisy.
677- launcher module; colorful app/window icons broke the semantic Nugu bar aesthetic.
679Center:
6811. media/player
6822. clock
684End:
6861. Mako indicator
6872. WiFi icon
6884. Bluetooth battery/status
6895. tray
6906. sys_info CPU
6917. volume
6928. brightness
6939. battery
69410. inhibit
69511. power menu
697Interaction polish:
699- All hover states use the same semantic accent background + on-focus foreground, including music and clipboard.
700- Generic `:checked` styling was removed; persistent state is explicit per widget.
701- Power and volume checked/focus states are explicitly neutral so clicking elsewhere clears visible highlight.
702- Clock popup time/month/year/arrows/days were screenshot-verified readable after GTK calendar selector fixes.
703- Clipboard grouped with left utilities; notifications grouped with right status.
704- Bar edge padding increased so power does not sit flush against the display edge.
705- Region/group spacing added between workspace/utility and right-side connectivity/metrics/inhibit groups.
706- Active workspace pill widened to make instant highlight easier to see.
707- WiFi polling relaxed to 30s because connected state is icon-only and detail action opens `impala`.
708- Ironbar systemd unit sets `GSK_RENDERER=cairo`; this removes GTK/Mesa Vulkan startup noise on X230 while staying around 1.5% CPU / 77M RSS after settling.
709- Destructive power actions were not clicked during validation.
710- Power popup visual test confirmed destructive off/reboot buttons sit away from the opener cursor side.
712## Open decisions
714- Media scroll: next/prev, volume, or none? Current: no scroll action.
715- Optional later: richer Mako popup/history UI. Current: compact count + restore/dismiss actions.

ironbar/config.json

Modified

+185 / −48 text lines

11{
2 "icon_theme": "Papirus",
2 "icon_theme": "Adwaita",
33 "position": "top",
44 "height": 30,
5 "popup_autohide": true,
6 "popup_gap": 4,
57 "start": [
68 {
7 "type": "workspaces",
8 "name_map": {
9 "web": "󰖟",
10 "code": "󰅨",
11 "term": "󰆍",
12 "chat": "󰭹",
13 "media": "󰎆",
14 "misc": "󰋖",
15 "scratch": "󰙀"
16 },
17 "favorites": ["web", "code", "term", "chat", "media"],
18 "format": "{icon}"
9 "type": "custom",
10 "name": "workspace-switcher",
11 "class": "nugu-workspaces",
12 "bar": [
13 {
14 "type": "box",
15 "widgets": [
16 {
17 "type": "button",
18 "class": "workspace-item",
19 "label": "#ws1",
20 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"1\" }))'"
21 },
22 {
23 "type": "button",
24 "class": "workspace-item",
25 "label": "#ws2",
26 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"2\" }))'"
27 },
28 {
29 "type": "button",
30 "class": "workspace-item",
31 "label": "#ws3",
32 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"3\" }))'"
33 },
34 {
35 "type": "button",
36 "class": "workspace-item",
37 "label": "#ws4",
38 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"4\" }))'"
39 },
40 {
41 "type": "button",
42 "class": "workspace-item",
43 "label": "#ws5",
44 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"5\" }))'"
45 },
46 {
47 "type": "button",
48 "class": "workspace-item",
49 "label": "#ws9",
50 "on_click": "!hyprctl eval 'hl.dispatch(hl.dsp.focus({ workspace = \"9\" }))'"
51 }
52 ]
53 }
54 ],
55 "tooltip": "Workspaces: web code term chat media misc"
1956 },
20 {
21 "type": "launcher",
22 "truncate": {
23 "mode": "end",
24 "max_length": 24
25 }
26 },
27 {
28 "type": "focused",
29 "truncate": {
30 "mode": "end",
31 "max_length": 64
32 }
33 }
34 ],
35 "center": [
36 {
37 "type": "music",
38 "player_type": "playerctl"
39 }
40 ],
41 "end": [
4257 {
4358 "type": "clipboard",
4459 "max_items": 5,
4863 }
4964 },
5065 {
51 "type": "tray"
66 "type": "bindmode",
67 "truncate": {
68 "mode": "end",
69 "max_length": 20
70 }
71 }
72 ],
73 "center": [
74 {
75 "type": "music",
76 "player_type": "mpris",
77 "format": "{title} / {artist}",
78 "truncate": {
79 "mode": "end",
80 "max_length": 42
81 }
82 },
83 {
84 "type": "clock",
85 "format": "%H:%M"
86 }
87 ],
88 "end": [
89 {
90 "type": "script",
91 "class": "mako-status",
92 "cmd": "~/.config/ironbar/scripts/mako-status.sh",
93 "mode": "poll",
94 "interval": 5000,
95 "on_click_left": "makoctl restore",
96 "on_click_right": "makoctl dismiss --all",
97 "tooltip": "Notifications: left restores last, right dismisses all"
98 },
99 {
100 "type": "script",
101 "class": "wifi",
102 "cmd": "~/.config/ironbar/scripts/wifi-status.sh",
103 "mode": "poll",
104 "interval": 30000,
105 "on_click_left": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"impala\")'",
106 "on_click_middle": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"impala\")'",
107 "tooltip": "WiFi: left/middle opens impala"
108 },
109 {
110 "type": "bluetooth",
111 "format": {
112 "not_found": "",
113 "disabled": "󰂲",
114 "enabled": "󰂯",
115 "connected": "󰂱",
116 "connected_battery": "󰂱 {device_battery_percent}%"
117 },
118 "disable_popup": true,
119 "on_click_left": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"bluetui\")'",
120 "on_click_middle": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"bluetui\")'",
121 "tooltip": "Bluetooth: left/middle opens bluetui"
122 },
123 {
124 "type": "tray",
125 "icon_size": 14
126 },
127 {
128 "type": "sys_info",
129 "format": [" {cpu_percent:1}%"],
130 "interval": {
131 "cpu": 2
132 },
133 "on_click_left": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"btm\")'",
134 "on_click_middle": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"btm\")'",
135 "tooltip": "System monitor: left/middle opens btm"
52136 },
53137 {
54138 "type": "volume",
55139 "on_scroll_up": "wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 2%+",
56140 "on_scroll_down": "wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%-",
57 "on_click_right": "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
141 "on_click_right": "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle",
142 "on_click_middle": "hyprctl eval 'require(\"scripts.tui_tab\").spawn(\"wiremix\")'",
143 "smooth_scroll_speed": 1.0,
144 "show_sources": false,
145 "tooltip": "Volume: scroll adjusts, right mutes, middle opens wiremix"
146 },
147 {
148 "type": "brightness",
149 "format": "{percentage}%",
150 "icon_label": "display-brightness-symbolic",
151 "mode": {
152 "type": "systemd",
153 "subsystem": "backlight",
154 "name": "intel_backlight"
155 },
156 "smooth_scroll_speed": 0.5,
157 "tooltip": "Brightness: scroll adjusts display"
58158 },
59159 {
60160 "type": "battery",
61 "show_if": "ls /sys/class/power_supply/ | grep -q '^BAT'"
161 "format": "{percentage}%",
162 "icon_size": 10,
163 "show_if": "ls /sys/class/power_supply/ | grep -q '^BAT'",
164 "profiles": {
165 "warning": {
166 "percent": 20
167 },
168 "critical": {
169 "when": {
170 "percent": 5,
171 "charging": false
172 },
173 "format": "󰂎 {percentage}%"
174 }
175 },
176 "tooltip": "Battery: left opens details"
62177 },
63178 {
64 "type": "clock",
65 "format": "%H:%M"
179 "type": "inhibit",
180 "durations": ["00:30:00", "01:00:00", "02:00:00", "inf"],
181 "default_duration": "00:30:00",
182 "format_on": "󰅶 {duration}",
183 "format_off": "󰛊 {duration}",
184 "tooltip": "Inhibit: left toggles, right cycles duration"
66185 },
67186 {
68187 "type": "custom",
92211 "widgets": [
93212 {
94213 "type": "button",
95 "class": "power-btn",
96 "label": "󰐥",
97 "on_click": "!systemctl poweroff"
214 "class": "power-btn danger",
215 "label": "󰐥 off",
216 "on_click": "!hyprshutdown --post-cmd \"systemctl poweroff\""
98217 },
99218 {
100219 "type": "button",
101220 "class": "power-btn",
102 "label": "󰜉",
103 "on_click": "!systemctl reboot"
221 "label": "󰜉 reboot",
222 "on_click": "!hyprshutdown --post-cmd \"systemctl reboot\""
104223 },
105224 {
106225 "type": "button",
107226 "class": "power-btn",
108 "label": "󰍃",
109 "on_click": "!loginctl terminate-session $XDG_SESSION_ID"
227 "label": "󰍃 out",
228 "on_click": "!hyprshutdown"
229 },
230 {
231 "type": "button",
232 "class": "power-btn",
233 "label": "󰤄 sleep",
234 "on_click": "!loginctl lock-session && systemctl suspend"
235 },
236 {
237 "type": "button",
238 "class": "power-btn",
239 "label": "󰌾 lock",
240 "on_click": "!hyprlock"
110241 }
111242 ]
243 },
244 {
245 "type": "label",
246 "name": "uptime",
247 "label": "up {{30000:uptime -p | cut -d ' ' -f2-}}"
112248 }
113249 ]
114250 }
115 ]
251 ],
252 "tooltip": "Power menu"
116253 }
117254 ]

ironbar/nugu.css

Modified

+4 / −1 text lines

99 --on-focus: #121212;
1010 --muted: #9d9d9d;
1111 --unfocus: #6f6f6f;
12 --error: #e46479;
12 --error: #ec6376;
13 --warning: #f0ee69;
14 --info: #3ec5e3;
15 --debug: #ed5eed;
1316 --border: #d86dd8;

ironbar/scripts/mako-status.sh

Added
new file mode 100755

+7 / −0 text lines

1#!/bin/sh
2
3count=$(makoctl list 2>/dev/null | grep -c '^Notification ')
4case "$count" in
5 0) printf '󰂚\n' ;;
6 *) printf '󰂞 %s\n' "$count" ;;
7esac

ironbar/scripts/wifi-status.sh

Added
new file mode 100755

+12 / −0 text lines

1#!/bin/sh
2
3station=${1:-wlan0}
4raw=$(iwctl station "$station" show 2>/dev/null | sed 's/\x1b\[[0-9;]*m//g')
5state=$(printf '%s\n' "$raw" | awk '/State/ {print $2; exit}')
6
7if [ "$state" != connected ]; then
8 printf '󰖪 off\n'
9 exit 0
10fi
12printf '󰖩\n'

ironbar/scripts/workspaces-watch.py

Added
new file mode 100755

+148 / −0 text lines

1#!/usr/bin/env python3
2
3import json
4import os
5import select
6import socket
7import subprocess
8import time
9from pathlib import Path
11WORKSPACES = [
12 ("1", "󰖟"),
13 ("2", "󰅨"),
14 ("3", "󰆍"),
15 ("4", "󰭹"),
16 ("5", "󰎆"),
17 ("9", "󰉋"),
18]
19EVENT_PREFIXES = (
20 "workspace",
21 "focusedmon",
22 "createworkspace",
23 "destroyworkspace",
24 "moveworkspace",
25 "openwindow",
26 "closewindow",
27 "movewindow",
28 "urgent",
29)
30last_vars: dict[str, str] = {}
31color_mtime = 0
32color_vars: dict[str, str] = {}
33hypr_socket_dir = ""
36def css_vars() -> dict[str, str]:
37 global color_mtime, color_vars
38 config_home = Path(os.environ.get("XDG_CONFIG_HOME", Path.home() / ".config"))
39 path = config_home / "ironbar" / "nugu.css"
40 mtime = path.stat().st_mtime_ns
41 if mtime == color_mtime:
42 return color_vars
43 colors: dict[str, str] = {}
44 for line in path.read_text().splitlines():
45 if ":" not in line:
46 continue
47 name, value = line.strip().rstrip(";").split(":", 1)
48 name = name.strip()
49 value = value.strip()
50 if name.startswith("--") and value.startswith("#"):
51 colors[name[2:]] = value
52 color_mtime = mtime
53 color_vars = colors
54 return colors
57def hypr_dir() -> str:
58 global hypr_socket_dir
59 if hypr_socket_dir:
60 return hypr_socket_dir
61 sig = os.environ.get("HYPRLAND_INSTANCE_SIGNATURE")
62 if not sig:
63 result = subprocess.run(("hyprctl", "instances", "-j"), text=True, capture_output=True, check=False)
64 instances = json.loads(result.stdout or "[]")
65 sig = instances[0]["instance"]
66 hypr_socket_dir = f"{os.environ['XDG_RUNTIME_DIR']}/hypr/{sig}"
67 return hypr_socket_dir
70def hypr_cmd(command: str) -> str:
71 with socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) as sock:
72 sock.settimeout(1)
73 sock.connect(f"{hypr_dir()}/.socket.sock")
74 sock.sendall(command.encode())
75 chunks: list[bytes] = []
76 while True:
77 chunk = sock.recv(65536)
78 if not chunk:
79 break
80 chunks.append(chunk)
81 return b"".join(chunks).decode("utf-8", "replace")
84def event_socket_path() -> str:
85 return f"{hypr_dir()}/.socket2.sock"
88def markup(ws_id: str, icon: str, active: str, occupied: set[str], colors: dict[str, str]) -> str:
89 if ws_id == active:
90 return '<span foreground="{}" background="{}" font_weight="bold"> {} </span>'.format(
91 colors["on-focus"],
92 colors["focus"],
93 icon,
94 )
95 if ws_id in occupied:
96 return '<span foreground="{}">{}</span>'.format(colors["fg"], icon)
97 return '<span foreground="{}">{}</span>'.format(colors["muted"], icon)
100def hypr_state() -> tuple[str, set[str]]:
101 active = json.loads(hypr_cmd("j/activeworkspace") or "{}")
102 workspaces = json.loads(hypr_cmd("j/workspaces") or "[]")
103 return str(active.get("id", "")), {str(ws.get("id")) for ws in workspaces if ws.get("windows", 0) > 0}
106def set_var(name: str, value: str) -> None:
107 if last_vars.get(name) == value:
108 return
109 subprocess.run(("ironbar", "var", "set", name, value), stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, check=False)
110 last_vars[name] = value
113def update() -> None:
114 colors = css_vars()
115 active, occupied = hypr_state()
116 for ws_id, icon in WORKSPACES:
117 set_var(f"ws{ws_id}", markup(ws_id, icon, active, occupied, colors))
120def watch() -> None:
121 global hypr_socket_dir
122 while True:
123 update()
124 try:
125 with socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) as sock:
126 sock.connect(event_socket_path())
127 pending = b""
128 while True:
129 ready, _, _ = select.select([sock], [], [], 10)
130 if not ready:
131 update()
132 continue
133 chunk = sock.recv(4096)
134 if not chunk:
135 break
136 pending += chunk
137 while b"\n" in pending:
138 raw, pending = pending.split(b"\n", 1)
139 line = raw.decode("utf-8", "replace")
140 if line.startswith(EVENT_PREFIXES):
141 update()
142 except Exception:
143 hypr_socket_dir = ""
144 time.sleep(1)
147if __name__ == "__main__":
148 watch()

ironbar/style.css

Modified

+480 / −73 text lines

2525#bar {
2626 background-color: var(--bg);
27 padding: 0 8px;
27 padding: 0 20px;
2828 border-bottom: 2px solid var(--accent);
3737button {
38 padding: 2px 8px;
38 min-height: 0;
39 padding: 1px 7px;
3940 border-radius: var(--radius);
4041 background: transparent;
43button:hover, button:active, button:checked {
44button:hover, button:active {
4445 background: var(--accent);
4546 color: var(--on-focus);
48.workspaces .item {
49 padding: 2px 8px;
49button:hover label,
50button:active label,
51button:hover image,
52button:active image {
53 color: var(--on-focus);
54}
56.nugu-workspaces {
57 margin-left: 4px;
58 margin-right: 10px;
59}
61.nugu-workspaces .workspace-item {
62 min-height: 0;
5063 margin: 0 2px;
51 border-radius: var(--radius);
64 padding: 1px 5px;
5265 color: var(--muted);
55.workspaces .item.focused {
56 background: var(--focus);
68.nugu-workspaces .workspace-item:hover {
69 background: var(--accent);
5770 color: var(--on-focus);
60.workspaces .item.focused label {
61 color: var(--on-focus);
62}
64.workspaces .item.visible {
65 color: var(--fg);
66}
68.workspaces .item.urgent {
69 background-color: var(--error);
70 color: var(--bg);
71}
73.launcher .item {
74 margin: 0 2px;
75 padding: 2px 6px;
76}
78.launcher .item.open {
79 box-shadow: inset 0 -2px var(--unfocus);
80}
82.launcher .item.focused {
83 color: var(--on-focus);
84 background: var(--focus);
85}
87.launcher .item.focused label {
88 color: var(--on-focus);
89}
91.popup-launcher {
92 padding: 8px;
93}
95.popup-launcher .popup-item {
96 padding: 8px 12px;
97 border-radius: var(--radius);
98}
100.popup-launcher .popup-item:hover {
101 background-color: var(--surface);
102}
104.focused {
105 color: var(--focus);
73.bindmode {
10674 margin-left: 8px;
75 padding: 1px 7px;
76 border-radius: var(--radius);
77 background: var(--warning);
78 color: var(--bg);
79 font-weight: bold;
10982.popup-music {
11891.volume {
119 margin: 0 4px;
92 margin: 0 7px;
12295.popup-volume {
12396 padding: 12px;
97 background-color: var(--bg-transparent);
98 color: var(--fg);
99}
101.popup-volume .device-box,
102.popup-volume .apps-box {
103 background-color: transparent;
104 color: var(--fg);
105}
107.popup-volume .device-selector,
108.popup-volume .device-selector button,
109.popup-volume dropdown,
110.popup-volume dropdown button {
111 background: var(--accent);
112 color: var(--on-focus);
113 border-radius: var(--radius);
114}
116.popup-volume .device-selector label,
117.popup-volume .device-selector arrow,
118.popup-volume .device-selector *,
119.popup-volume dropdown button,
120.popup-volume dropdown button * {
121 background: transparent;
122 color: var(--on-focus);
123}
125.popup-volume .btn-mute {
126 color: var(--fg);
127}
129.popup-volume .btn-mute:hover,
130.popup-volume .btn-mute:checked {
131 background: var(--accent);
132 color: var(--on-focus);
133}
135popover listview,
136popover list,
137popover row,
138popover modelbutton {
139 background-color: var(--bg);
140 color: var(--fg);
141}
143popover listview row,
144popover list row {
145 padding: 6px 10px;
146}
148popover listview row label,
149popover list row label,
150popover row label,
151popover modelbutton label {
152 color: var(--fg);
153}
155popover listview row:hover,
156popover list row:hover,
157popover row:hover,
158popover modelbutton:hover {
159 background-color: var(--accent);
160 color: var(--on-focus);
161}
163popover listview row:hover label,
164popover list row:hover label,
165popover row:hover label,
166popover modelbutton:hover label {
167 color: var(--on-focus);
168}
170popover listview row:selected,
171popover list row:selected,
172popover row:selected,
173popover modelbutton:checked {
174 background-color: var(--focus);
175 color: var(--on-focus);
176}
178popover listview row:selected label,
179popover list row:selected label,
180popover row:selected label,
181popover modelbutton:checked label {
182 color: var(--on-focus);
183}
185/* GTK dropdown popovers are separate popovers, not children of .popup-volume. */
186popover contents listview,
187popover contents list,
188popover contents row,
189popover contents modelbutton,
190popover contents button {
191 background: var(--bg);
192 color: var(--fg);
193}
195popover contents row *,
196popover contents modelbutton *,
197popover contents button * {
198 color: var(--fg);
199}
201popover contents row:hover,
202popover contents modelbutton:hover,
203popover contents button:hover {
204 background: var(--accent);
205 color: var(--on-focus);
206}
208popover contents row:hover *,
209popover contents modelbutton:hover *,
210popover contents button:hover * {
211 color: var(--on-focus);
212}
214popover contents row:selected,
215popover contents modelbutton:checked,
216popover contents button:checked {
217 background: var(--focus);
218 color: var(--on-focus);
219}
221popover contents row:selected *,
222popover contents modelbutton:checked *,
223popover contents button:checked * {
224 color: var(--on-focus);
225}
227.popup-volume dropdown popover,
228.popup-volume dropdown popover contents,
229.popup-volume dropdown popover listview,
230.popup-volume dropdown popover row {
231 background: var(--bg);
232 color: var(--fg);
233}
235.popup-volume dropdown popover label,
236.popup-volume dropdown popover row *,
237.popup-volume dropdown popover listview * {
238 color: var(--fg);
239}
241.popup-volume dropdown popover row:hover {
242 background: var(--accent);
243}
245.popup-volume dropdown popover row:selected {
246 background: var(--accent);
247}
249.popup-volume dropdown popover row:selected * {
250 color: var(--on-focus);
251}
253scale trough {
254 min-height: 6px;
255 min-width: 6px;
256 background-color: var(--unfocus);
257 border-radius: var(--radius);
126260scale highlight {
261 min-height: 6px;
262 min-width: 6px;
127263 background-color: var(--accent);
128264 border-radius: var(--radius);
267.brightness {
268 margin: 0 7px;
269 color: var(--fg);
270}
131272.battery {
132 margin: 0 4px;
133 color: var(--focus);
273 margin: 0 7px;
274 color: var(--fg);
275}
277.battery.warning {
278 color: var(--warning);
279}
281.battery.critical {
282 color: var(--error);
283 font-weight: bold;
284}
286.popup-battery {
287 padding: 10px 12px;
288 background-color: var(--bg-transparent);
289 color: var(--fg);
290}
292.popup-battery .details {
293 color: var(--muted);
294}
296.inhibit {
297 margin: 0 7px 0 12px;
298 color: var(--muted);
299}
301.inhibit button:checked,
302.inhibit button:active {
303 background: var(--accent);
304 color: var(--on-focus);
136307.clock {
137308 font-weight: bold;
138 margin: 0 4px;
309 margin: 0 7px;
139310 color: var(--accent);
313.popup-clock {
314 padding: 12px;
315 background-color: var(--bg-transparent);
316 color: var(--fg);
317}
319.popup-clock *,
320.popup-clock calendar.view header,
321.popup-clock calendar.view header *,
322.popup-clock calendar.view header stack.month,
323.popup-clock calendar.view header label.year {
324 color: var(--fg);
325}
327.popup-clock .calendar-clock {
328 background: var(--accent);
329 color: var(--on-focus);
330 border-radius: var(--radius);
331 padding: 2px 8px;
332 margin-bottom: 8px;
333}
335.popup-clock .calendar-clock,
336.popup-clock .calendar-clock * {
337 color: var(--on-focus);
338 font-weight: bold;
339}
341.popup-clock calendar {
342 background: transparent;
343 color: var(--fg);
344 border-radius: var(--radius);
345}
347.popup-clock calendar header {
348 border-bottom: 1px solid var(--unfocus);
349 padding-bottom: 6px;
350 margin-bottom: 6px;
351}
353.popup-clock calendar button:hover,
354.popup-clock calendar.view header button:hover,
355.popup-clock calendar.view header button:hover * {
356 background: var(--accent);
357 color: var(--on-focus);
358}
360.popup-clock calendar grid label.day-name,
361.popup-clock calendar grid label.week-number {
362 color: var(--muted);
363}
365.popup-clock calendar grid label.day-number {
366 color: var(--fg);
367 border-radius: var(--radius);
368}
370.popup-clock calendar grid label.other-month {
371 color: var(--unfocus);
372}
374.popup-clock calendar grid label.today {
375 color: var(--accent);
376 font-weight: bold;
377}
379.popup-clock calendar grid label:selected {
380 background: var(--focus);
381 color: var(--on-focus);
382}
384.music {
385 margin: 0 7px;
386 color: var(--fg);
387}
389.clipboard {
390 margin: 0 10px 0 12px;
391}
142393.popup-clipboard {
143394 padding: 8px;
146397.popup-clipboard .item {
147398 padding: 4px 8px;
148399 border-radius: var(--radius);
400 color: var(--fg);
401}
403.popup-clipboard .item label {
404 color: var(--fg);
151407.popup-clipboard .item:hover {
152 background-color: var(--surface);
408 background-color: var(--accent);
409 color: var(--on-focus);
410}
412.popup-clipboard .item:hover label {
413 color: var(--on-focus);
414}
416.mako-status {
417 margin: 0 7px 0 12px;
418 color: var(--fg);
419}
421.wifi {
422 margin: 0 7px;
423 color: var(--fg);
424}
426.bluetooth {
427 margin: 0 7px;
428}
430.bluetooth.disabled,
431.bluetooth.not-found {
432 color: var(--muted);
433}
435.bluetooth.enabled {
436 color: var(--fg);
437}
439.bluetooth.connected {
440 color: var(--fg);
155443.tray {
156 margin: 0 4px;
444 margin: 0 7px 0 12px;
159447.tray popover contents {
163451.power-menu {
164 margin-left: 4px;
452 margin-left: 12px;
453}
455.power-menu button,
456.power-menu #power-btn {
457 color: var(--muted);
458}
460.power-menu button:hover,
461.power-menu #power-btn:hover {
462 background: var(--accent);
463 color: var(--on-focus);
464}
466.power-menu button:checked,
467.power-menu button:focus,
468.power-menu #power-btn:checked,
469.power-menu #power-btn:focus {
470 background: transparent;
471 color: var(--muted);
167474.popup-power-menu {
168475 padding: 12px;
476 background-color: var(--bg-transparent);
477 color: var(--fg);
171480.popup-power-menu #header {
172481 font-size: 14px;
173482 font-weight: bold;
174483 margin-bottom: 8px;
484 padding-bottom: 8px;
175485 color: var(--accent);
486 border-bottom: 1px solid var(--unfocus);
487}
489.popup-power-menu #buttons {
490 margin-bottom: 8px;
178493.popup-power-menu .power-btn {
179 background-color: var(--surface);
180 border: 1px solid var(--accent);
494 background-color: transparent;
495 border: 1px solid var(--unfocus);
181496 border-radius: var(--radius);
182 padding: 6px 12px;
183 margin: 0 4px;
184 font-size: 16px;
497 padding: 6px 10px;
498 margin: 0 3px;
499 color: var(--fg);
187502.popup-power-menu .power-btn:hover {
188503 background-color: var(--accent);
189 color: var(--bg);
504 border-color: var(--accent);
505 color: var(--on-focus);
192.notifications .count {
193 font-size: 10px;
508.popup-power-menu .power-btn.danger {
509 border-color: var(--error);
510}
512.popup-power-menu .power-btn.danger:hover {
194513 background-color: var(--accent);
195 color: var(--bg);
196 border-radius: 50%;
197 padding: 2px 5px;
514 border-color: var(--accent);
515 color: var(--on-focus);
516}
518.popup-power-menu #uptime {
519 color: var(--muted);
200522.sysinfo {
201 margin: 0 4px;
523 margin: 0 7px 0 16px;
204526.sysinfo > .item + .item {
205527 margin-left: 8px;
530.music:hover,
531.clipboard:hover,
532.mako-status:hover,
533.wifi:hover,
534.bluetooth:hover,
535.tray:hover,
536.sysinfo:hover,
537.volume:hover,
538.brightness:hover,
539.battery:hover,
540.inhibit:hover,
541.clock:hover {
542 background: var(--accent);
543 color: var(--on-focus);
544 border-radius: var(--radius);
545}
547.music:hover label,
548.clipboard:hover label,
549.mako-status:hover label,
550.wifi:hover label,
551.bluetooth:hover label,
552.tray:hover label,
553.sysinfo:hover label,
554.volume:hover label,
555.brightness:hover label,
556.battery:hover label,
557.inhibit:hover label,
558.clock:hover label {
559 color: var(--on-focus);
560}
562.music:checked,
563.music:focus,
564.clipboard:checked,
565.clipboard:focus,
566.mako-status:checked,
567.mako-status:focus,
568.wifi:checked,
569.wifi:focus,
570.bluetooth:checked,
571.bluetooth:focus,
572.tray:checked,
573.tray:focus,
574.sysinfo:checked,
575.sysinfo:focus,
576.volume:checked,
577.volume:focus,
578.volume button:checked,
579.volume button:focus,
580.brightness:checked,
581.brightness:focus,
582.battery:checked,
583.battery:focus,
584.clock:checked,
585.clock:focus {
586 background: transparent;
587 color: var(--fg);
588}
590.music:checked label,
591.music:focus label,
592.clipboard:checked label,
593.clipboard:focus label,
594.mako-status:checked label,
595.mako-status:focus label,
596.wifi:checked label,
597.wifi:focus label,
598.bluetooth:checked label,
599.bluetooth:focus label,
600.tray:checked label,
601.tray:focus label,
602.sysinfo:checked label,
603.sysinfo:focus label,
604.volume:checked label,
605.volume:focus label,
606.brightness:checked label,
607.brightness:focus label,
608.battery:checked label,
609.battery:focus label,
610.clock:checked label,
611.clock:focus label {
612 color: var(--fg);
613}
208615.popup {
209616 padding: 8px;

mako/nugu.conf

Modified

+8 / −8 text lines

1717[urgency=critical]
1818background-color=#242424ff
1919text-color=#f3effbff
20border-color=#e46479ff
21progress-color=over #e46479ff
20border-color=#ec6376ff
21progress-color=over #ec6376ff
2323[summary~="[Ee]rror|[Ff]ailed|[Ff]ailure|[Cc]rash"]
24border-color=#e46479ff
25progress-color=over #e46479ff
24border-color=#ec6376ff
25progress-color=over #ec6376ff
2727[summary~="[Ww]arn|[Ww]arning"]
28border-color=#9e9a69ff
29progress-color=over #9e9a69ff
28border-color=#f0ee69ff
29progress-color=over #f0ee69ff
3131[summary~="[Ii]nfo|[Nn]otice"]
32border-color=#3ec5ddff
33progress-color=over #3ec5ddff
32border-color=#3ec5e3ff
33progress-color=over #3ec5e3ff

nugu/ironbar.nu

Modified

+3 / −0 text lines

2020 --muted: ($p.ui.minor);
2121 --unfocus: ($p.ui.unfocus);
2222 --error: ($p.error);
23 --warning: ($p.warning);
24 --info: ($p.info);
25 --debug: ($p.debug);
2326 --border: ($p.ui.accent);

pi/.gitignore

Modified

+1 / −0 text lines

11agent/auth.json
2/.demo

pi/agent/settings.json

Modified

+3 / −3 text lines

1414 "minimax/MiniMax-M2.7-highspeed",
1515 "minimax/MiniMax-M2.5-highspeed"
1616 ],
17 "defaultProvider": "openai-codex",
18 "defaultModel": "gpt-5.5",
17 "defaultProvider": "minimax",
18 "defaultModel": "MiniMax-M3",
1919 "defaultThinkingLevel": "high",
2020 "quietStartup": true,
2121 "collapseChangelog": true,
7676 "q": {
7777 "model": "minimax/MiniMax-M2.7-highspeed"
7878 }
79}No final newline
79}

polkit/10-brightness.rules

Added
new file mode 100644

+6 / −0 text lines

1polkit.addRule(function(action, subject) {
2 if (action.id == "org.freedesktop.login1.set-brightness" &&
3 subject.local && subject.active) {
4 return polkit.Result.YES;
5 }
6});

udev/backlight.rules

Added
new file mode 100644

+2 / −0 text lines

1ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/usr/bin/chgrp video /sys/class/backlight/intel_backlight/brightness"
2ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/usr/bin/chmod g+w /sys/class/backlight/intel_backlight/brightness"

wezterm/bugabinga/key_binds.lua

Modified

+5 / −0 text lines

212212 {
213213 key = 'z',
214214 mods = 'LEADER',
215 action = workspace_switcher.switch_workspace_in_new_window(),
216 },
217 {
218 key = 'Z',
219 mods = 'LEADER|SHIFT',
215220 action = workspace_switcher.switch_workspace(),
216221 },
217222 {

wezterm/bugabinga/mux.lua

Added
new file mode 100644

+14 / −0 text lines

1local wez = require 'wezterm'
2
3return function ( cfg )
4 if not wez.target_triple:find( 'linux', 1, true ) then return end
5
6 cfg.unix_domains = {
7 {
8 name = 'unix',
9 no_serve_automatically = true,
10 },
11 }
13 cfg.default_gui_startup_args = { 'connect', 'unix' }
14end

wezterm/bugabinga/options.lua

Modified

+5 / −1 text lines

2424 if wez.target_triple:find( 'linux', 1, true ) and os.getenv 'WAYLAND_DISPLAY' then
2525 cfg.enable_wayland = true
2626 end
27 cfg.font_size = 13
27 if wez.hostname() == 'x230' then
28 cfg.font_size = 11
29 else
30 cfg.font_size = 13
31 end
2832end

wezterm/bugabinga/status.lua

Modified

+1 / −0 text lines

105105end
107107local domain_label = function ( domain )
108 if domain == 'unix' then return 'MUX', wez.nerdfonts.cod_server or wez.nerdfonts.cod_terminal or '□', palette.info end
108109 if not domain or domain == 'local' or domain == 'Local' then return host_domain() end
109110 if domain:find( '^WSL:', 1, false ) then return 'WSL', wez.nerdfonts.dev_linux or '□', palette.ui.important_local end
110111 if domain:find( '^scope:', 1, false ) then return 'EXE', wez.nerdfonts.cod_gear or '□', palette.warning end

wezterm/systemd/wezterm-mux-server.service

Added
new file mode 100644

+11 / −0 text lines

1[Unit]
2Description=WezTerm mux server
3Documentation=https://wezterm.org/multiplexing.html
4
5[Service]
6ExecStart=/usr/bin/wezterm-mux-server
7Restart=on-failure
8RestartSec=2
9
10[Install]
11WantedBy=default.target

wezterm/wezterm.lua

Modified

+1 / −0 text lines

44require 'bugabinga.theme' ( cfg )
55require 'bugabinga.startup' ( cfg )
66require 'bugabinga.options' ( cfg )
7require 'bugabinga.mux' ( cfg )
78require 'bugabinga.key_binds' ( cfg )
89require 'bugabinga.mouse_binds' ( cfg )
910require 'bugabinga.window' ( cfg )

x230.symlinks

Modified

+6 / −0 text lines

106106hypr/systemd/ironbar.service
107107~/.config/systemd/user/ironbar.service
109hypr/systemd/ironbar-workspaces.service
110~/.config/systemd/user/ironbar-workspaces.service
112wezterm/systemd/wezterm-mux-server.service
113~/.config/systemd/user/wezterm-mux-server.service
109115fontconfig
110116~/.config/fontconfig