feat(maestro): spawn form defaults command to claude + prefills cwd to daemon home dir (NAP-328)
Two web spawn QoL improvements plus the wire support they need: - Command field now prefills `claude` instead of an empty box. - Working directory prefills the selected daemon's home dir, updating on daemon change unless the user has typed their own value. The daemon resolves its `$HOME` via `dirs::home_dir()` at startup and advertises it end-to-end: a new `home_dir` field on `DaemonOutbound::Hello` flows through the registry's `register` into `DaemonInfo` (served on `/api/daemons` and `/api/events`). The field is `#[serde(default)]`, so older daemons that omit it deserialize to an empty string — backward compatible, and the UI simply skips prefill when it's empty. Hierarchical `/`-separated labels in the web sidebar already worked (web/src/catalog.ts); no change there. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -22,6 +22,9 @@ export interface DaemonInfo {
|
||||
hostname: string;
|
||||
version: string;
|
||||
daemon_url: string;
|
||||
/** Home dir of the user the daemon runs as; used to prefill the spawn form's
|
||||
* working directory. Empty/absent for older daemons. */
|
||||
home_dir?: string;
|
||||
}
|
||||
|
||||
export interface WorktreeSpec {
|
||||
|
||||
Reference in New Issue
Block a user