Commit Graph

459 Commits

Author SHA1 Message Date
Miguel Palhas 5ba12d3684 refactor: move pi's AGENTS.md concat into the agent-skills module
All four tools' context wiring lives there now; this file just installs
the package.
2026-08-19 15:14:43 +01:00
Miguel Palhas 231b6bdb28 refactor: get opencode rules and shared commands from agent-skills
opencode has no @file imports, so the shared home-manager module
concatenates the claude-md fragments into .config/opencode/AGENTS.md
(the screenshots line moved there as a fragment) and links commands/
into place. Keeps only the opencode-specific agents, commands and
skills here.
2026-08-19 15:14:43 +01:00
naps62 46bb060208 Merge pull request 'chore: pin the noctalia input to a rev' (#2) from noctalia-pin into main
CI / lint (push) Successful in 29s
CI / eval (push) Successful in 2m18s
Reviewed-on: #2
2026-08-19 13:11:36 +01:00
Miguel Palhas 189196fb88 chore: pin the noctalia input to a rev
CI / lint (pull_request) Successful in 29s
CI / eval (pull_request) Successful in 1m51s
noctalia publishes no binary cache, so `flake update` means a local Qt/QML
build every time. quickshell comes from nixpkgs and is cached, so the
nixpkgs follows stays; only the noctalia ref is pinned.

Pinned to the rev already locked, so this rebuilds nothing.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-19 12:29:22 +01:00
Miguel Palhas 849cd3a5ef chore: sync aoe structured-session toggle from yolo
CI / lint (push) Successful in 38s
CI / eval (push) Successful in 2m26s
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-19 12:22:23 +01:00
Miguel Palhas 013d41aa72 feat: add the pi coding agent harness
CI / lint (push) Successful in 33s
CI / eval (push) Successful in 2m9s
Packages the prebuilt pi release binary and puts it on PATH alongside
Claude Code, Codex and opencode.

pi has no `@file` imports in context files, so the shared agent-skills
fragments are concatenated into ~/.pi/agent/AGENTS.md. Skills need no
wiring: pi already reads ~/.agents/skills.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-19 11:57:24 +01:00
Miguel Palhas 0a4dd8a192 fix: bypass the ssh agent for github on yolo
CI / lint (push) Successful in 30s
CI / eval (push) Successful in 2m4s
gpg-agent is the ssh agent here, and signing blocks forever on a pinentry
prompt with no TTY, so git push hung right after "Server accepts key".
The key file has no passphrase, so read it directly instead.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 21:11:28 +01:00
Miguel Palhas 8efd0a1139 feat: give yolo a distinct amber cursor
CI / lint (push) Successful in 30s
CI / eval (push) Successful in 1m56s
yolo's desktop is only ever seen through a Moonlight window, so its cursor
needs to be tellable apart from the client's at a glance. Bibata-Modern-Amber
differs in both colour and silhouette from Nordzy.

Threads the theme through an option rather than setting it in one place: it
was hardcoded in cursor.nix, in hl.env, in the setcursor autostart, and twice
more in darkman's mode scripts, which re-set it on every light/dark switch and
would have reverted the override.

Also drops a stale hl.env pointing HYPRCURSOR_THEME at rose-pine-hyprcursor,
which no host installs.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 16:06:01 +01:00
Miguel Palhas de527df7c4 feat: stream yolo at 4k
virtio-gpu exposes no NVENC/VAAPI, so sunshine software-encodes. Measured
x264 (superfast+zerolatency) on the 8 vCPUs: 73fps at 2160p against 135fps
at 1440p, so a 60fps client keeps roughly 20% margin.

Also brings the drifted agent-of-empires config upstream, which the
mutableFiles guard required before switching.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 15:56:56 +01:00
Miguel Palhas c7eb5796ea fix: grant sunshine access to /dev/uinput
hardware.uinput, enabled by services.sunshine, sets /dev/uinput to
root:uinput 0660 and adds no members to the group. Sunshine runs as a
user service, so it failed to create the virtual mouse, keyboard and
gamepads and the stream carried no input.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 15:43:55 +01:00
Miguel Palhas 3ee2f4db10 feat: run the aoe web dashboard as a service
CI / lint (push) Successful in 33s
CI / eval (push) Successful in 2m12s
Auth is off in the unit: traefik + authelia front it, and aoe rejects
--auth none on a wildcard bind unless --behind-proxy says so.
2026-08-18 09:28:32 +01:00
Miguel Palhas 886af193a2 Merge remote-tracking branch 'origin/main' into images
CI / lint (push) Successful in 28s
CI / eval (push) Successful in 1m55s
2026-08-18 09:18:29 +01:00
Miguel Palhas 4a8f8d330c fix: make clip2path safe and ssh-aware
Text paste went through `kitty @ send-text`, which has no bracketed
paste, so multi-line clipboard text ran line by line in a shell. Route
text through `kitty @ action paste_from_clipboard` instead and keep
send-text for the image path only.

Over SSH the typed path pointed at the local /tmp and the remote process
could not read it. Read the focused window's foreground processes from
`kitty @ ls`, and when one of them is an ssh client, scp the image to
that host and type the remote path. Nothing is typed into the focused
app but a path, so this still works when the target is a TUI rather than
a shell. The real ssh process is preferred over the `kitten ssh`
wrapper, whose long options the argument parser does not understand.

Also: mktemp instead of a timestamp that collides within a second,
a prune of clip files older than a day, image/png preferred over
whatever format the source advertises first, and the clipboard tools
pinned so the script does not depend on kitty's inherited PATH.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 08:30:20 +01:00
Miguel Palhas 92a7273ff3 fix: let yolo inherit the common claude model
CI / lint (push) Successful in 29s
CI / eval (push) Successful in 1m53s
yolo pinned model to claude-fable-5[1m] while common sets opus[1m].
/model writes the live value into ~/.claude/settings.json, so any switch
away from fable-5 left the file drifted and mutableFiles aborted
activation on the next `nh home switch`. Dropping the override makes the
repo agree with the model actually in use.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 08:24:00 +01:00
Miguel Palhas 05037e40d8 refactor: dissolve the agent-deck tmux block
CI / lint (push) Successful in 30s
CI / eval (push) Successful in 1m59s
The block came from the agent-deck installer and was carried in wholesale
when the config was ported to nix. The tool is not installed on any host
and nothing else references it, and now that the file is rendered
read-only from the nix store the installer could not update its own block
anyway.

It re-declared default-terminal, history-limit and mouse at their existing
values, and escape-time at 0 — which quietly overrode the deliberate 25ms
two sections above it, along with the comment explaining that 0 breaks Alt
keys over SSH. Keeps the parts that do real work: the alternate-screen
override, extended keys, and the mouse scroll and drag-to-copy bindings.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 08:17:45 +01:00
Miguel Palhas d417a27f2d feat: make the clipboard work across tmux, ssh and hosts
CI / lint (push) Successful in 31s
CI / eval (push) Successful in 2m1s
tmux copy bindings piped to xclip, which is X11-only and never worked
under Hyprland or over SSH, and set-clipboard was never enabled, so the
vi-mode `y` binding was dead too. Route both through OSC 52 instead.
terminal-features has to name the outer terminal explicitly: tmux skips
OSC 52 silently when the terminfo entry does not claim the capability,
which is the common case for an SSH session on xterm-256color.

Neovim only falls back to OSC 52 when it finds no clipboard tool, but
wl-clipboard is installed on every host, so over SSH it wrote the remote
clipboard. Pin the OSC 52 provider for SSH sessions only.

Moonlight and Sunshine have no clipboard channel in the protocol, so
nothing at the terminal layer can help there. Add kdeconnect on all three
hosts for that, and start its indicator from Hyprland — kdeconnectd is
DBus-activated and nothing else brings it up at login.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 08:14:17 +01:00
Miguel Palhas c79436d340 refactor: fix yolo config drift and restart traps
CI / lint (push) Successful in 32s
CI / eval (push) Successful in 2m7s
yolo's .claude/settings.json was a full fork of the common file, not the
narrow override its comment claimed: sandbox, defaultMode, voiceEnabled,
$schema and feedbackSurveyState were absent, and five more keys had
diverged. It now holds only yolo's overrides and merges over common via
recursiveUpdate. sandbox.enabled stays pinned false — inheriting it would
newly sandbox every Bash call on a box built for unattended agents.

mutableFiles maps a source back to a repo path for the "bring changes
upstream" hint, which only works inside the flake tree. Generated sources
would print a /nix/store path to copy onto, so add upstreamPath.

rev and rev-deploy set Restart=always with RestartSec=2, which burns
systemd's default 5-starts-per-10s budget and parks the unit in `failed`
until a manual reset-failed. StartLimitIntervalSec=0 lifts the cap.

programs.nh.flake and home.mutableFilesRepoPath become mkDefault so yolo
overrides them plainly instead of with mkForce in three places.

Also clears the outstanding nixfmt and statix findings. The yolo system
derivation hash is unchanged.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 07:32:08 +01:00
Miguel Palhas 6a08ec3805 Merge remote-tracking branch 'origin/moonlight'
CI / lint (push) Successful in 30s
CI / eval (push) Successful in 2m5s
2026-08-17 18:22:56 +01:00
Miguel Palhas 51f6cb013f fix: drop sunshine fec_percentage to 1
At the default 20, FEC mangles large frames and moonlight draws horizontal
bands over an otherwise-fine stream, with no error on either side.
2026-08-17 18:22:52 +01:00
Miguel Palhas fbf5ce2616 fix: stream real frames from yolo instead of a black picture
Three separate faults, each producing a black Moonlight stream:

- sunshine's wlr backend takes wlr-screencopy's dmabuf path, which on this
  virtio-gpu returns empty buffers. Reproduced locally over 127.0.0.1, so it
  is not the network or the client. Switch to kms capture.
- hypridle locked the session and cut dpms, blanking the captured output with
  no console to unlock from. Disable it on this host.
- qemu picked the nvidia render node by readdir order, so virgl fell back to
  llvmpipe. Pin renderD128 via the VM's args.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-17 17:48:41 +01:00
Miguel Palhas df319322b9 fix: authenticate nix github fetches to dodge the 60/hr rate limit
CI / lint (push) Successful in 29s
CI / eval (push) Failing after 20m25s
Unauthenticated flake input fetches from github.com were hitting 429.
Token lives in /etc/nix/github-token.conf (root:root 600, out-of-band —
never in git or /nix/store) and nix.conf !includes it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-17 15:03:31 +01:00
Miguel Palhas 65b95bb1fa feat: enable moonlight streaming client on konishi
CI / lint (push) Successful in 26s
CI / eval (push) Failing after 17m42s
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-17 14:37:44 +01:00
Miguel Palhas 352700fdab fix: point nvchad-starter to git.naps.pt/naps62/nvim-config, add /bin/bash symlink
CI / lint (push) Successful in 29s
CI / eval (push) Failing after 20m59s
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-17 14:29:39 +01:00
naps62 395055ed35 Merge remote-tracking branch 'origin/main' into yolo
CI / lint (push) Successful in 32s
CI / eval (push) Successful in 2m28s
# Conflicts:
#	home/common/programs/default.nix
2026-08-17 13:09:04 +00:00
naps62 2873d37bda chore: drop notify-hermes hooks
Removes 4 hook entries; PermissionRequest and SubagentStop had no others.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 13:05:41 +00:00
naps62 c57a430fd6 feat: chrome and agent-browser only on yolo
Drops zen-browser and downloads-cleanup. agent-browser was a global npm
install; nixpkgs has it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:57:25 +00:00
naps62 a8880c1441 docs: record why the igpu is unused
pve hardcodes egl-headless with no rendernode, and the nvidia egl vendor
outranks mesa, so virgl lands on llvmpipe.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:50:15 +00:00
naps62 c4a20f6152 docs: record the proxmox vm settings
vga: virtio-gl, serial0 and ovmf are load-bearing and live only on the
hypervisor, so a rebuilt vm would regress silently.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:47:02 +00:00
naps62 738f4cd03f feat: port the tmux config
156-line .tmux.conf plus tpm plugins existed only on the ubuntu box.
Plugins are declared instead of git-cloned at runtime by tpm.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:44:16 +00:00
naps62 dd04becb9c chore: drop pipx
Its test suite fails to build on this nixpkgs pin, blocking the whole
generation.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:40:59 +00:00
Miguel Palhas a8593d9157 wl kbptr
CI / lint (push) Successful in 32s
CI / eval (push) Failing after 1m39s
2026-08-17 13:39:37 +01:00
Miguel Palhas af28175e1c home: clear four eval warnings
All pre-existing, all mechanical:

- pointerCursor no longer implies generation from the block alone; set enable.
- top-level elixir_1_18 alias is deprecated for the beamPackages set. Same
  derivation, 1.18.4 either way.
- pkgs.system -> pkgs.stdenv.hostPlatform.system.
- fzf and atuin both bind Ctrl-R. Atuin is sourced last so it already owned the
  key; historyWidget.zsh.command = "" states that explicitly and satisfies
  home-manager's conflict check. Behaviour is unchanged and fzf keeps Ctrl-T
  and Alt-C.
2026-08-17 13:39:37 +01:00
Miguel Palhas 4028c55d56 hyprland: add wl-kbptr, patched for HiDPI and rotated outputs
Keyboard control of the mouse pointer. SUPER+G labels detected targets and
clicks one; SUPER+SHIFT+G falls back to tile -> bisect for anything detection
misses.

Stock wl-kbptr 0.4.1 is unusable on this setup, for two unrelated reasons:

- Target detection is hardcoded for ~1080p. filter_rects() discards any
  candidate with height >= 50 or width >= 500, so on a 4K screen at scale = 1
  nearly every real control is dropped for being "too big" and only emoji and
  avatars survive — a full Slack window produced ~8 labels, all on images.

- On the rotated monitor the pointer landed in the wrong place. move_pointer()
  takes output->width/height from xdg_output.logical_size, which is already
  rotated, then applies the transform again. Asking for global (4000,1000) on
  DP-2 landed at (4286,3726); the double rotation predicts (4301,3736).

Neither is exposed as a config option, hence the overrideAttrs. Sizes in the
config file are likewise doubled: wl-kbptr paints raw cairo onto a layer
surface and never sees a scale factor, so upstream's defaults render half-size.

Both binds are pidof-guarded: wl-kbptr only exits on a keypress, so an overlay
that loses focus first sits there holding an exclusive keyboard grab.
2026-08-17 13:39:37 +01:00
naps62 21d9f89674 feat: add missing cli tooling
Ports what was apt-installed on the ubuntu box. rtk matters most: the
claude hooks rewrite commands through it, and it silently no-ops without.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:39:11 +00:00
naps62 4ce204d46f chore: drop postgresql from yolo
Nothing connects to it — every database here runs in a container.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 12:15:06 +00:00
naps62 38bfd6a76d fix: raise sunshine fd limit
It leaks a /dev/dri/renderD fd per encoder probe, hits the 1024 default,
and mesa can then no longer dlopen the GBM driver — capture degrades to a
black picture with no error surfaced.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 09:05:28 +00:00
naps62 c97f5999e5 chore: bump agent-skills for hooks and scripts
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:56:53 +00:00
naps62 37e44b9a3d fix: sunshine capture value is wlr, not wlgrab
wlgrab is the name the backend logs under, not a valid config value.
Sunshine rejects it, then starts anyway with no encoder — moonlight sees
a 503.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:51:55 +00:00
naps62 1cddd495cd feat: alias a=aoe
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:44:33 +00:00
naps62 4dcf84d41c feat: per-host claude settings and machine profile
settings.json carries skipDangerousModePermissionPrompt and the rev hook
wiring, so yolo gets its own; other hosts keep the shared one. Machine
profile picks which agent-skills machines/<name>.md is imported.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:39:08 +00:00
naps62 032cea0db8 feat: adopt agent-skills, scope aoe config to yolo
Drops the stale skills/commands/CLAUDE.md from home/common/programs/claude
in favour of the agent-skills flake, which is the maintained copy. The
module keeps what agent-skills does not own: packages, statusline and
settings.json.

aoe's config.toml moves to home/yolo — it sets yolo_mode_default, which
starts sessions with permission checks skipped.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:35:08 +00:00
Miguel Palhas 1f94b29d56 wip
CI / lint (push) Successful in 34s
CI / eval (push) Failing after 1m41s
2026-08-17 09:18:11 +01:00
naps62 352b87192d fix: disable zram on yolo, use aoe-with-web
zram wedged shutdown faulting stored pages back in, and the VM already
has a real swap partition. aoe-with-web is the same binary plus `serve`.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:12:48 +00:00
naps62 4bea767b2e feat: serial console on yolo
Needed before switching to vga: virtio-gl, which leaves no QEMU console
surface for noVNC or screendump.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 08:05:24 +00:00
naps62 2e23c695a2 feat: install codex cli, add yolo ssh host aliases
cliPackage only points the desktop app at codex; it never put the cli on
PATH, so `codex` was missing.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:59:34 +00:00
naps62 e0e71a44d1 chore: drop claude-rc
No longer used.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:49:39 +00:00
naps62 0501db564d fix: create claude-rc log dir
systemd does not create the parent of StandardOutput=append:, failing
every instance with 209/STDOUT on a fresh machine.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:46:26 +00:00
naps62 52618a852a feat: add node and pnpm to the shared dev tooling
nodejs.nix shipped only the language server, so a fresh machine has no
node runtime — rev's clone cannot install its dependencies.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:44:08 +00:00
naps62 0fa1a31489 fix: flattened repo layout under ~/tea
Repos moved from ~/tea/<org>/<repo> to ~/tea/<repo>, so the rev and
agent-skills unit paths no longer resolved. Also captures aoe schema keys
added on first run.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:40:42 +00:00
naps62 bb65e34bca chore: move yolo flake path to ~/tea/nixos-config
Also overrides the home-manager nh.flake, which sets NH_FLAKE and was
still pointing at the ~/projects default, so bare `nh home switch` never
resolved on this host.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-17 07:38:15 +00:00