No description
  • Python 49.2%
  • TypeScript 25.5%
  • Nix 9.6%
  • Shell 6.1%
  • Lua 4.5%
  • Other 5.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-17 21:27:32 -05:00
docs docs 12: record the accepted native-slot flicker + reverted debounce experiment 2026-10-11 23:27:59 -04:00
files AGENTS.md: OpenBao login address is 10.30.20.21 after the c1 re-IP 2026-11-17 21:27:32 -05:00
hosts Revert "arch-ws: trust the production lab root CA for CLI TLS (SSL_CERT_FILE bundle, node extra)" 2026-11-16 13:07:39 -05:00
modules helix: generate config.toml and languages.toml per host 2026-11-15 14:13:47 -05:00
.gitignore pacman: declare our Forgejo registry and its packages 2026-09-30 22:15:02 -04:00
.luarc.json hypr: manage lua tooling (.luarc.json, .stylua.toml); repo-root copies drive editing this repo 2026-09-28 16:21:02 -04:00
.stylua.toml hypr: manage lua tooling (.luarc.json, .stylua.toml); repo-root copies drive editing this repo 2026-09-28 16:21:02 -04:00
AGENTS.md agents: home-manager skill — switch semantics, add -N, daemon reload gotcha; repo AGENTS.md pointer 2026-11-02 11:39:36 -05:00
flake.lock flake update: hm+dms to 2026-10-19, nixpkgs-unstable to 2026-10-08 tip 2026-10-19 14:49:24 -04:00
flake.nix home+flake: C-translation-unit comment restructure — section headers, func-style annotations 2026-10-29 16:39:04 -04:00
home.nix radiance: talk to it on 127.0.0.1, not the workstation LAN address 2026-11-17 21:27:15 -05:00
options.nix pacman: declare our Forgejo registry and its packages 2026-09-30 22:15:02 -04:00
README.md kitty: native DMS light/dark follow on wayfinder via *-theme.auto.conf 2026-10-11 18:20:56 -04:00
Taskfile.yml guard plugins: bun test suite (task test) + dialect rewrites for && and 2>&1 2026-11-03 18:25:27 -05:00

home-manager

Home Manager setup on Arch

Usage

task setup
# And then assuming the system hostname is registered
task switch


home-manager switch --flake .#ginjiruu@<hostname> -b backup
nix flake update
# after nix flake update: if activation warns about GPU drivers, run
#   sudo $(which non-nixos-gpu-setup)

Layout

home.nix                  shared base — keep host divergence OUT of here
hosts/arch-ws.nix         desktop deltas (LG panel tuning, gamescope pin)
hosts/wayfinder-ws.nix    laptop deltas (touchpad, focus-follows-mouse)
files/hypr/hyprland.lua   shared lua (stylua-formatted)
files/hypr/workspaces.lua shared scratch-workspace rules
files/hypr/hosts/*.lua    per-host lua, appended after the shared file
files/dms/                dms backup tarball for cross-host config parity
files/bin/                laptop session-glue scripts (theme sync watchers)
files/autostart/          KeePassXC autostart .desktop (laptop)
files/systemd/            generator-unit drop-ins we own (laptop)
files/opencode/           opencode.json + AGENTS.md (shared, both hosts)
files/helix/themes/       helix themes written by hx-theme-sync (laptop)
docs/                     session-record docs (migrated from the CustomDesktop
                          repo 2026-09-29); "docs NN" below = docs/NN-*.md

Host lua is appended via lib.mkAfter on extraConfig, so a later hl.config() in the host file overrides the shared one.

Scope

Managed (HM-owned, store-backed symlinks):

  • ~/.config/hypr/hyprland.lua — from files/hypr/hyprland.lua + host lua
  • ~/.config/hypr/workspaces.lua — via extraLuaFiles
  • ~/.config/hypr/binds-user.lua — via extraLuaFiles, identical on all hosts. Edit keybinds here; the DMS Control Center keybind editor writes ~/.config/hypr/dms/binds-user.lua, which is no longer required by hyprland.lua (it stays around, inert).
  • ~/.config/hypr/.luarc.json + .stylua.toml — lua_ls/stylua config (repo-root copies double as the settings for editing this repo itself).
  • ~/.config/opencode/opencode.json + AGENTS.md — shared opencode config, identical on all hosts (files/opencode/; converted from arch-ws's V1 config to native V2). Providers: vllm (session model, arch-ws GPU via LAN IP), vllm-paro, and arch-ws's three local llama-* endpoints (inert on wayfinder). ~/.config/opencode/cli.json/tui.jsonc are deliberately NOT managed — they reference host-local herdr plugin files. First switch: delete the pre-existing real files at both paths (rule 9).
  • ~/.config/voxtype/config.toml — voxtype dictation config, identical on all hosts (files/voxtype/; keybinds already shared via binds-user.lua SUPER+;). Binaries/units follow the syncthing pattern: pacman/AUR owns voxtype/voxtype-bin, home.nix mirrors the user unit + enablement. Host-local, NOT HM's territory (both one-time, both survive switches): the whisper model (~1.6G, ~/.local/share/voxtype/models) via voxtype setup --download, and the engine variant via sudo voxtype setup gpu --enable — the source-build package defaults the /usr/bin/voxtype symlink to voxtype-native (CPU!) and a package upgrade can reset it; check with voxtype info accel, re-run the setup command if GPU dropped. First switch on arch-ws: delete the pre-existing real file (rule 9).
  • ~/.config/kitty/kitty.conf — programs.kitty, fully unified in home.nix, byte-identical on all hosts (14 pt font, blur, tab-bar layout, window/tab keybinds; ported from the loose ~/.config/kitty files on 2026-10-08). package = null (pacman owns the binary — my.pacman.packages). No daemon unit: kitty exits with its last window, so the hypr bind (kitty --single-instance) lazily spawns the instance and later launches join it over the singleton socket (allow_remote_control yes). SIGUSR1 live-reloads config (module onChange + hx-theme-sync). Colors are split out to files/kitty/dank-dark.conf (appended via extraConfig) so hosts can diverge without diverging kitty.conf: wayfinder-ws drops kitty/{dark,light,no-preference}-theme.auto.conf slots in (hosts/wayfinder-ws.nix) and kitty follows DMS light/dark natively via the portal (kitty ≥0.38, doc 12); arch-ws ships no slots and stays dank-dark-locked for its OLED panel. cleanKittyAutoThemes moves DMS-era real *-theme.auto.conf strays aside (kitty ≥0.38 consumes them — no longer inert). First switch: the migrateKittyConfig activation moves the pre-existing real kitty.conf to kitty.conf.pre-hm.bak.
  • ~/.config/starship.toml — adopted from arch-ws (wayfinder was running starship defaults); starship init fish already fires in config.fish. First switch on arch-ws: migrateStarshipConfig moves the real file to .pre-hm.bak.

Laptop-only (hosts/wayfinder-ws.nix; docs 07/11/12/13/15), all migrated from loose host files on 2026-09-28:

  • Units gsd-xsettings + dconf-theme-sync — real systemd.user.services.
  • ~/.local/bin/{dconf,hx}-theme-sync — store-backed, executable.
  • KeePassXC autostart .desktop + the generator-unit drop-in that orders it after the DMS tray host. Never resurrect keepassxc.service.
  • Helix: config.toml (store-owned, pins theme = "current") + static themes {apple,clrs,dank}.toml. Theme switching uses the pointer-theme pattern: hx-theme-sync rewrites the watcher-owned themes/current.toml (inherits = "ayu_light|ayu_evolve") and SIGUSR1s helix, which re-reads theme files from disk — helix's only drop-in slot (no config includes, no --theme flag in ≤25.07; default is a reserved unshadowable name, so a zero-theme-line config can't work). RETIRE this once Arch ships helix >25.07: main has native [theme] light/dark driven by the terminal's mode-2031 reports, so config.toml just carries that table and the pointer file + helix leg of hx-theme-sync go away.

Desktop-only (hosts/arch-ws.nix), migrated 2026-09-28:

  • Units syncthing — HM mirrors the package unit so enable state is declarative (pacman still owns the binary; keep the ExecStart in sync with /usr/lib/systemd/user/syncthing.service on package bumps). voxtype moved to home.nix (shared, 2026-09-29 wayfinder adoption).
  • hypr-bitwarden-popup + its listener script (script moved out of yadm).
  • comfyui-qwen-image, elephant, vllm-tcclaviger, vllm-paro-int5 — adopted from loose host units; activation pending (the switch restarts the inference server; move the 4 host unit files + their default.target.wants symlinks aside before switching). The vllm units wrap run.sh → docker compose; model lifecycle lives in the container.
  • Deleted as dead: the whole llama-server-*/llama-router stack (binaries gone), af-portforward/af-vm-pf, and hermes-gateway — hermes was removed via its official hermes uninstall --full plus the actual runtime, a hermes-discord docker container, image, and ~/.hermes.
  • tray.target is NOT stale — the current HM generates it (shared target for tray-related service modules); leave it be.
  • Dropped unused packages incl. hyprpolkitagent — DMS's built-in polkit agent (PolkitService.qml, on by default) replaces it. If auth prompts ever stop appearing, that's the first thing to check.

Deliberately NOT managed (apps write these at runtime — HM managing them caused a broken session once):

  • ~/.config/hypr/dms/* — generated by DMS (dms setup / Control Center), including dms/binds-user.lua (inert since keybinds moved to this repo)
  • ~/.config/DankMaterialShell/*.json — GUI-managed settings
  • ~/.config/hypr/scripts/ — yadm (arch-ws only), except bitwarden-hypr-listener.sh — HM-owned now (unit + script versioned together in hosts/arch-ws.nix; untracked from yadm 2026-09-28)
  • ~/.config/helix/themes/current.toml — pointer theme rewritten by hx-theme-sync at runtime (the drop-in slot; config.toml itself is managed)

The hypridle/hyprlock/hyprpaper/wayscriber stack is gone from both hosts — DMS owns idle, lock, wallpaper, and screenshots now.

DMS GUI state across hosts

~/.config/DankMaterialShell/* is deliberately host-specific (OLED vs laptop panel: themes, bar widgets, power/lock timeouts) and GUI-written — never store-managed. dms backup create/restore exists as an escape hatch (files/dms/dms-backup.tar.gz is an arch-ws snapshot, kept for disaster recovery only). Cross-host consistency is achieved in the lua layer instead: hyprland.lua, workspaces.lua, and binds-user.lua are identical on all hosts by construction (this repo); dms/binds.lua is byte-identical as of 2026-09-28 (desktop regenerated from the laptop's fresh copy) but can drift again via per-host dms keybinds state — check it after dms bumps.

Rules

  1. Store-backed sources only. Never mkOutOfStoreSymlink into this repo (sshd StrictModes + reload races — see the 2026-09-28 incident).
  2. Always switch with -b backup.
  3. After any switch touching hypr: hyprctl binds | wc -l should match the host's baseline (arch-ws ~1271; wayfinder-ws ~1291). A drop to ~31 means the lua failed to load.
  4. No secrets in this repo, ever.
  5. After nix flake update: if activation warns "GPU drivers require an update", run sudo $(which non-nixos-gpu-setup) or nix GUI apps (DMS) lose EGL. Provided by targets.genericLinux.gpu.
  6. Re-vendor the dms template on every dms bump. files/hypr/hyprland.lua is our fork of DMS's embedded template (baseline: dms a609b5f, verified 2026-09-28 — no unadopted upstream content). dms setup would overwrite it and cannot (store symlink), so upstream template changes must be pulled in manually:
    HOME=$(mktemp -d) dms setup headless --compositor hyprland --terminal kitty
    # then diff the generated hyprland.lua against files/hypr/hyprland.lua
    # and adopt anything new on the template side.
    
  7. PAM bridge (lock screen): nixpkgs linux-pam hardcodes its password helper at /run/wrappers/bin/unix_chkpwd (NixOS path) — see HM #7027. The bridge file is now HM-managed (files/pam/tmpfiles-nix-pam-chkpwd.conf, installed by the installPamStacks activation). Without it the DMS lock screen CANNOT authenticate (PAM code 9) and will faillock-lock the account after 3 tries. On Arch the helper is /usr/sbin/unix_chkpwd (setuid); on other distros adjust the link target.
  8. PAM stacks + nix module gap: /etc/pam.d/{dms-lock,greetd,sudo} are HM-managed (files/pam/, installed by the same activation; pacman/AUR upgrades get healed on the next switch). Factor order everywhere: key → finger → password; single credential source ~/.config/Yubico/u2f_keys (/etc/u2f_mappings retired — it rotted into terminal escape codes and silently disabled U2F for login/sudo). Same gap as rule 7 on the module side: nix linux-pam's module dir has no pam_u2f/pam_fprintd, so dms-lock's factor lines must stay absolute paths (/usr/lib/security/…), else quickshell logs "adding faulty module" and the lock screen degrades to password-only.
  9. If a stale wants-symlink to a pacman dms.service exists when the HM unit arrives, HM refuses to clobber it — remove ~/.config/systemd/user/graphical-session.target.wants/dms.service manually, re-switch.

Ownership map

Path Owner
hyprland binary pacman
dms binary pacman (AUR dms-shell-git; HM module disabled 2026-09-29 A/B — session unit mirrored in home.nix)
quickshell (session) pacman (quickshell-git; also hard dep of greetd-dms-greeter on wayfinder-ws; arch-ws has no DMS greeter)
dgop, cava, matugen, NM, accountsservice, … pacman
~/.config/hypr/{hyprland,workspaces}.lua HM (this repo)
~/.config/hypr/dms/, ~/.config/DankMaterialShell/, ~/.local/state/DankMaterialShell/ DMS runtime (nobody)
~/.config/hypr/scripts/ (arch-ws only) yadm
/etc/pam.d/{dms-lock,greetd,sudo} + /etc/tmpfiles.d/nix-pam-chkpwd.conf HM activation (this repo, files/pam/)
everything else yadm (arch-ws) / unversioned (wayfinder-ws)