feat(firstmate): add explicit fm-oc2 launcher alias and test all three aliases
fm and fm-oc2 both run oc2 from the firstmate home. fm-pi stays the explicit Pi fallback. The launcher check now sources the generated zshrc, runs each alias against spies, and asserts the working directory and that fm and fm-oc2 launch identically. The readme records that the aliases share one firstmate home and its task records but keep separate chat histories, so the running primary must be quit before starting the other.
This commit is contained in:
1 parent
53206f0a7b
commit
208e6741f3
3 files changed
+104
-58
No files matched your search
@@ -13,13 +13,15 @@ The firstmate crew dispatch + Gitea PR helper are wired by `darwin-rebuild`, but
|
||||
cd ~/Documents/investor-flow
|
||||
git remote set-url origin http://unraid.local:3003/transnet/investor-flow
|
||||
|
||||
Verify: `fm` launches OpenCode 2 as the first mate and `fm-pi` is the explicit Pi fallback; `oc2 --version` prints the Homebrew opencode version; `pi --list-models mimo` shows `opencode-go/mimo-v2.5-pro`; `tea pulls list --repo transnet/investor-flow` works.
|
||||
Verify: `fm` and `fm-oc2` launch OpenCode 2 as the first mate and `fm-pi` is the explicit Pi fallback; `oc2 --version` prints the Homebrew opencode version; `pi --list-models mimo` shows `opencode-go/mimo-v2.5-pro`; `tea pulls list --repo transnet/investor-flow` works.
|
||||
|
||||
## firstmate launcher and crew model routing
|
||||
|
||||
`fm` is the permanent firstmate launcher. It changes to `~/Documents/firstmate` and executes `~/.local/bin/oc2`, which runs the Homebrew OpenCode build with the isolated `~/.config/opencode2/opencode.json` config. `fm-pi` remains only as an explicit Pi fallback. Never make Pi the default launcher.
|
||||
`fm` is the permanent firstmate launcher. `fm-oc2` is the same launcher under its explicit OpenCode 2 name, so both aliases expand to the same command. They change to `~/Documents/firstmate` and execute `~/.local/bin/oc2`, which runs the Homebrew OpenCode build with the isolated `~/.config/opencode2/opencode.json` config. `fm-pi` starts Pi instead and remains only an explicit fallback. Never make Pi the default launcher.
|
||||
|
||||
`home.nix` owns both aliases, so a rebuild regenerates them. The installed `~/.zshrc` changes only at the next activation.
|
||||
The three aliases share one firstmate home. They read the same task records, inbox, and state. Each tool keeps its own chat history, so a conversation in OpenCode 2 does not appear in Pi, and the reverse. Quit the running primary before you start the other one. A single firstmate home serves one primary at a time.
|
||||
|
||||
`home.nix` owns all three aliases, so a rebuild regenerates them. The installed `~/.zshrc` changes only at the next activation.
|
||||
|
||||
Worker routing lives in `home/.config/firstmate/crew-dispatch.json`, which is symlinked to `~/Documents/firstmate/config/crew-dispatch.json`:
|
||||
|
||||
@@ -55,7 +57,7 @@ The captain confirmed the split on 2026-11-15. Leave it unchanged:
|
||||
./tests/run.sh # all checks
|
||||
```
|
||||
|
||||
The launcher check sources the real generated zshrc in an interactive zsh. A `pi` spy on PATH and an `OPENCODE2_BIN` spy capture the launch, so no firstmate session starts.
|
||||
The launcher check sources the real generated zshrc in an interactive zsh. A `pi` spy on PATH and an `OPENCODE2_BIN` spy capture the launch of `fm`, `fm-oc2`, and `fm-pi`, record the working directory, and exit at once, so no firstmate session starts.
|
||||
|
||||
### Install after merge
|
||||
|
||||
@@ -65,7 +67,7 @@ The Nix sources in this repository are the durable record. The live files are ge
|
||||
2. Confirm `readlink ~/.dotfiles` names the checkout that holds the merged commit.
|
||||
3. Run `./rebuild.sh` from that checkout.
|
||||
4. Run `./tests/fm-launcher.sh --live` and `./tests/crew-dispatch.sh`.
|
||||
5. Open a fresh shell and run `alias fm`. It must show `exec /Users/laptran/.local/bin/oc2`.
|
||||
5. Open a fresh shell and run `alias fm fm-oc2 fm-pi`. `fm` and `fm-oc2` must show `exec /Users/laptran/.local/bin/oc2`, and `fm-pi` must show `exec pi`.
|
||||
|
||||
### Checkout topology and safe installation
|
||||
|
||||
|
||||
Reference in new issue
Block a user