repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

docs(nugu): update theming skill workflow

d0ad14f7603a9830811bd518e401a5250beeded9

Oliver Jan Krylow <oliver@bugabinga.net> ·

SSH signature · not checked

Browse filesCompare with HEAD

Changed files (1)

+22 / −83 text lines

Diff layout

pi/agent/skills/nugu/SKILL.md

Modified

+22 / −83 text lines

11---
22name: nugu
3description: Use when editing the Nugu color theme, semantic palette, generated app themes, terminal colors, or dotfiles integrations that mention nugu.
3description: Use when another project needs Nugu-derived theme files or color integration.
44---
66# Nugu
8Personal semantic color system: `~/Workspace/dotfiles/nugu`.
9Nugu is a palette generator first, app theme files second.
8Use Nugu's semantic palette to generate theme artifacts for another project.
11## Source of Truth
10## Sources of truth
13- `base.toml` — seed colors and human intent comments.
14- `nugu.nu` — palette generation, WCAG contrast checks, terminal preview.
15- `palette.nu` — reads generated `output/dark.toml` and `output/light.toml`.
16- `helix.nu`, `wezterm.nu`, `ghostty.nu` — app-specific generators.
17- `helix_nugu_stub.toml` — static Helix theme scaffold.
18- `output/` — generated, gitignored; do not treat as source.
12If `DOTFILES` is set, first try `$DOTFILES/nugu`; verify it contains
13`base.toml`, `nugu.nu`, and `justfile`. Otherwise locate the Nugu source
14repository from the current host/project. Do not guess a filesystem path.
20## Palette Semantics
16Read:
22Global colors:
18- `$DOTFILES/nugu/base.toml` — seed colors and semantic intent
19- `$DOTFILES/nugu/nugu.nu` — palette generation and checks
20- relevant `$DOTFILES/nugu/*.nu` generator — target mapping
21- `$DOTFILES/nugu/justfile` — recipes, targets, destinations
24- `error` — urgent, aggressive, nonnegotiable.
25- `warning` — likely problem, distracting but ignorable.
26- `info` — context suggestion, relaxed.
27- `debug` — intentionally easy to spot.
29Both `content` and `ui` contain:
31- `normal`, `backdrop`, `accent`, `minor`, `focus`, `unfocus`, `important_local`, `important_global`
33`content.*` is main text/content. `ui.*` is chrome, borders, panels, frame, status UI.
34Prefer changing generation formulas over hard-coding per-app colors.
23If multiple roots exist, use the one referenced by the target project.
24If none is discoverable, ask before generating.
3626## Workflow
38From `nugu/`:
281. Inspect target format, config, output path, and dark/light support.
292. Reuse the relevant Nugu generator and recipe.
303. Add missing mappings to Nugu source, never to generated app themes.
314. Generate both modes where supported.
325. Write only requested target artifacts; never edit generated `output/`.
336. Leave active-mode selection to target runtime config.
347. Distinguish generated, installed, and loaded/rendered state.
358. Do not claim loaded/rendered state without checking it.
40```bash
41just lint
42just fmt
43just check
44just build
45just show dark
46just show light
47```
49Targeted generators:
51```bash
52just helix
53just wezterm
54just ghostty
55just install # helix + wezterm + ghostty; writes into sibling/live config dirs
56```
58`just check` runs generation validation + WCAG threshold reporting. Investigate warnings before accepting palette changes.
60## Integration Contract
621. Inspect sibling generators and `justfile` before designing an integration.
632. Source colors from `nugu.nu`, never another app's generated theme or exports.
643. Generate and install both dark and light variants, following sibling conventions.
654. Leave variant selection to app config/runtime; generation must not select an active mode.
665. Do not add default-mode or apply commands unless explicitly requested as shared Nugu behavior.
676. Test from Nugu source inputs, not pre-existing generated artifacts.
68 Generate required intermediates inside the test workspace and validate every variant.
70## Editing Rules
72- Start with semantic intent: what role/color behavior should change?
73- Update `base.toml` only for seed semantics; update `nugu.nu` for derived palette behavior.
74- Update app generator files only when mapping from semantics to app-specific fields changes.
75- Avoid editing generated `output/*` directly.
76- If generated files are copied into tracked dotfiles (`ghostty/themes/*`, WezTerm palette modules, Helix themes), regenerate via recipes unless user asks for manual patching.
77- Preserve dark/light symmetry unless change is intentionally mode-specific.
78- Preserve contrast thresholds unless user explicitly wants changed accessibility policy.
80## Known Integrations
82- Neovim: `neovim/colors/nugu.lua`, `neovim/lua/bugabinga/nugu/`, colorscheme `nugu`.
83- Helix: `helix/config.toml` uses `theme = "nugu-dark"`.
84- WezTerm: `wezterm/bugabinga/nugu/`, generated `palette_dark.lua` / `palette_light.lua`.
85- Ghostty: `ghostty/config` uses `theme = light:nugu-light,dark:nugu-dark`; generated themes in `ghostty/themes/`.
86- tmux: `tmux/tmux.conf` has Nugu color section.
87- Other refs: `cmus/nugu.theme`, `clipse/nugu.json`, TODOs for LS_COLORS/firefox/nushell/yazi.
89## Tools
91Nugu recipes assume these CLIs exist:
93- `nu` / `nu-check`
94- `just`
95- `taplo`
96- `pastel`
98Use the `pastel` skill when doing nontrivial color conversion, contrast exploration, mixing, or palette design.
37Preserve semantic roles, dark/light symmetry, and Nugu contrast policy.