Skip to content

feat(settings): a Settings window, heed://set, and settings that take as written - #47

Merged
rbstp merged 1 commit into
masterfrom
settings-window
Sep 27, 2026
Merged

rbstp merged 1 commit into
masterfrom
settings-window

Conversation

@rbstp

@rbstp rbstp commented Sep 27, 2026

Copy link
Copy Markdown
Owner

Heed read its settings at launch and on SIGHUP, so every defaults write in the README came with a make restart, and the Raycast store review caught the extension's README skipping that step. This removes the step instead.

Settings take as written

A key-value observer on the defaults domain reloads the running agent whenever one of its keys changes, from whichever process changed it. The SIGHUP handler is gone; killall -HUP Heed now just restarts it through KeepAlive, which applies the settings too. A run of writes lands as one reload, 50 ms after the last.

One table

Setting.swift lists every setting with its key, kind, range and Config field. Config.load reads through it, so a key cannot be in the loader and missing from the window or the URL vocabulary. Ranges and defaults are the ones the loader had.

The window

Settings… in the menu bar menu, or heed://settings. A tab per group; a field per shortcut that says whether its combination registered, with the log saying why when it did not; checkboxes and numbers for the rest; a list per exclusion, one entry per line. It edits the defaults domain and lets the reload apply the change, so the window, defaults write and the URL verbs are one path. Closing commits what was typed, an Edit menu makes paste work in an accessory app, and Restore Defaults asks before wiping everything.

The verbs

heed://set/<key>/<value>, heed://reset/<key>, heed://hotkeys/release, heed://hotkeys/restore, heed://settings, and the same as --set, --reset, --hotkeys and --settings on the binary. A set value survives the distributed-notification round trip whole, slashes included; lists are comma-separated, so a pattern with a comma goes through the window.

A URL can now change any setting, which the README's paragraph on the trade says plainly: register a combination another app needs, release every shortcut, exclude every window, turn on verbose. Nothing is read back.

Docs

README and the site drop every defaults write plus make restart pair for the window or a heed://set. The Configuration table stays as the key reference for set.

Checked

swift test passes, including round-trip and front-door cases for the new verbs. Installed locally: a defaults write and a heed://set each reload the running agent, a shortcut typed in the window re-registers, a change made by URL while a field is focused is not clobbered when that field ends editing. Two adversarial reviews (Opus and Codex) ran on the diff; their findings on the own-write race, edits lost on close, the missing Edit menu, clamped display, list guards and the security paragraph are all in.

The Raycast extension's README moves to the new way in the store follow-up once this is released.

… as written

Heed read its settings at launch and on SIGHUP, so every defaults write in
the README came with a restart. A key-value observer on the defaults domain
now reloads the running agent whenever a key changes, from whichever process
changed it, and the SIGHUP handler is gone. A run of writes lands as one
reload.

The settings are one table, Setting.swift, and Config.load reads through it.
The same table draws a Settings window, opened from the menu bar menu or
heed://settings: a tab per group, a field per shortcut that says whether its
combination registered, checkboxes and numbers for the rest, and a list per
exclusion. The window edits the defaults domain and lets the reload apply the
change, so it and defaults write are one path. Closing commits, an Edit menu
lets a bundle ID be pasted, and Restore Defaults asks first.

New verbs for the same table: heed://set/<key>/<value>, heed://reset/<key>,
heed://hotkeys/release and restore, and heed://settings, with --set, --reset,
--hotkeys and --settings on the binary. A set value survives the notification
round trip whole, slashes included.

The README and the site drop every defaults write and make restart pair, and
the paragraph on what a command can do says so honestly now that a URL can
change a setting.
@rbstp
rbstp merged commit ee7b28a into master Sep 27, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant