@aeolus-fleet/trierarch 0.17.3 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +18 -16
  3. package/dist/adapters/claude-code.d.ts +11 -1
  4. package/dist/adapters/claude-code.js +32 -10
  5. package/dist/adapters/claude-code.js.map +1 -1
  6. package/dist/adapters/codex.d.ts +10 -1
  7. package/dist/adapters/codex.js +15 -4
  8. package/dist/adapters/codex.js.map +1 -1
  9. package/dist/adapters/command-line.d.ts +15 -0
  10. package/dist/adapters/command-line.js +17 -0
  11. package/dist/adapters/command-line.js.map +1 -0
  12. package/dist/adapters/files.d.ts +9 -0
  13. package/dist/adapters/files.js +16 -0
  14. package/dist/adapters/files.js.map +1 -1
  15. package/dist/adapters/flags.d.ts +2 -2
  16. package/dist/adapters/flags.js +2 -2
  17. package/dist/adapters/git-workspace.js +1 -1
  18. package/dist/adapters/harnesses.d.ts +10 -2
  19. package/dist/adapters/harnesses.js +26 -3
  20. package/dist/adapters/harnesses.js.map +1 -1
  21. package/dist/adapters/json-state.d.ts +6 -4
  22. package/dist/adapters/json-state.js +21 -21
  23. package/dist/adapters/json-state.js.map +1 -1
  24. package/dist/adapters/log.d.ts +39 -0
  25. package/dist/adapters/log.js +65 -0
  26. package/dist/adapters/log.js.map +1 -0
  27. package/dist/adapters/paths.d.ts +1 -0
  28. package/dist/adapters/paths.js +1 -0
  29. package/dist/adapters/paths.js.map +1 -1
  30. package/dist/adapters/rest-fleet.d.ts +4 -3
  31. package/dist/adapters/rest-fleet.js +38 -18
  32. package/dist/adapters/rest-fleet.js.map +1 -1
  33. package/dist/adapters/service.js +18 -15
  34. package/dist/adapters/service.js.map +1 -1
  35. package/dist/adapters/style.d.ts +18 -0
  36. package/dist/adapters/style.js +38 -0
  37. package/dist/adapters/style.js.map +1 -0
  38. package/dist/cli/config-check.d.ts +11 -2
  39. package/dist/cli/config-check.js +26 -5
  40. package/dist/cli/config-check.js.map +1 -1
  41. package/dist/cli/init.d.ts +2 -2
  42. package/dist/cli/init.js +41 -15
  43. package/dist/cli/init.js.map +1 -1
  44. package/dist/cli/list.d.ts +7 -4
  45. package/dist/cli/list.js +18 -8
  46. package/dist/cli/list.js.map +1 -1
  47. package/dist/cli/main.js +33 -16
  48. package/dist/cli/main.js.map +1 -1
  49. package/dist/cli/prompter.d.ts +4 -0
  50. package/dist/cli/prompter.js +18 -3
  51. package/dist/cli/prompter.js.map +1 -1
  52. package/dist/cli/run.d.ts +13 -8
  53. package/dist/cli/run.js +48 -27
  54. package/dist/cli/run.js.map +1 -1
  55. package/dist/cli/status.d.ts +13 -4
  56. package/dist/cli/status.js +43 -17
  57. package/dist/cli/status.js.map +1 -1
  58. package/dist/core/check-settings.d.ts +25 -0
  59. package/dist/core/check-settings.js +52 -0
  60. package/dist/core/check-settings.js.map +1 -0
  61. package/dist/core/entry.d.ts +18 -30
  62. package/dist/core/entry.js +3 -1
  63. package/dist/core/entry.js.map +1 -1
  64. package/dist/core/handle-delivery.d.ts +9 -14
  65. package/dist/core/handle-delivery.js +4 -133
  66. package/dist/core/handle-delivery.js.map +1 -1
  67. package/dist/core/options-schema.d.ts +7 -0
  68. package/dist/core/options-schema.js +10 -0
  69. package/dist/core/options-schema.js.map +1 -0
  70. package/dist/core/ports.d.ts +60 -6
  71. package/dist/core/reconciler.d.ts +32 -12
  72. package/dist/core/reconciler.js +107 -23
  73. package/dist/core/reconciler.js.map +1 -1
  74. package/dist/core/report-self.d.ts +16 -0
  75. package/dist/core/report-self.js +41 -0
  76. package/dist/core/report-self.js.map +1 -0
  77. package/dist/core/run-pass.d.ts +8 -4
  78. package/dist/core/run-pass.js +135 -56
  79. package/dist/core/run-pass.js.map +1 -1
  80. package/dist/index.d.ts +2 -2
  81. package/dist/index.js.map +1 -1
  82. package/package.json +7 -5
  83. package/dist/core/answers.d.ts +0 -4
  84. package/dist/core/answers.js +0 -27
  85. package/dist/core/answers.js.map +0 -1
  86. package/dist/core/check-want.d.ts +0 -32
  87. package/dist/core/check-want.js +0 -80
  88. package/dist/core/check-want.js.map +0 -1
package/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @aeolus-fleet/trierarch
2
2
 
3
- Keeps the ships on its wanted list crewed on the machine it runs on: it starts, restarts, wakes and stops their sessions. It crews ships with `fleet:crew`; it never commissions or retires them. What a trierarch does is in [docs/trierarch.md](../../docs/trierarch.md); how this package is built is in [docs/architecture.md](../../docs/architecture.md#the-trierarch). Optional, like squadrons.
3
+ Keeps the ships whose crew requests are assigned to it crewed on the machine it runs on: it starts, restarts, wakes and stops their sessions, and writes each request's status. It crews with `crew:run`, which reaches only the ships assigned to it; it never commissions, retires or picks them. The trierarch plugin assigns them. What a trierarch does is in [docs/trierarch.md](../../docs/trierarch.md); how this package is built is in [docs/architecture.md](../../docs/architecture.md#the-trierarch). Optional, like squadrons.
4
4
 
5
5
  ## Install
6
6
 
@@ -12,8 +12,8 @@ npm install --global @aeolus-fleet/trierarch
12
12
 
13
13
  That gives the command `aeolus-trierarch`.
14
14
 
15
- 1. In the console, commission the trierarch's own ship: type `trierarch`, with **Crew ships** (`fleet:crew`). Keep its starting prompt open: it shows the ship id and the secret.
16
- 2. Set up the machine:
15
+ 1. Join the machine through the trierarch plugin (`machines.join`): it commissions the trierarch's own ship, type `trierarch` with `crew:run`, and answers its starting prompt and a setup line, `npx @aeolus-fleet/trierarch init --fleet-url <url> --ship-id <id> --secret <secret>`, shown once.
16
+ 2. Set up the machine with that line, or with `init` alone, which asks for what is missing:
17
17
 
18
18
  ```sh
19
19
  aeolus-trierarch init
@@ -24,7 +24,8 @@ That gives the command `aeolus-trierarch`.
24
24
  - whether Claude Code launches with `--dangerously-skip-permissions` and with `--remote-control` (both no unless you say yes);
25
25
  - where `codex` runs or Codex is configured already: whether to offer Codex, and whether it launches with `--dangerously-bypass-approvals-and-sandbox` (no unless you say yes). Every Codex session launches with `--no-daemon` whatever the flags, so stopping it stops its work;
26
26
  - the repositories it may make worktrees of, by name and path;
27
- - the caps: how many ships on its list, how many sessions at once.
27
+ - the folders it may crew a ship in as they are, by name and path. It trusts each one, so a session there starts with no trust question;
28
+ - the caps: how many ships it takes, how many sessions run at once.
28
29
 
29
30
  It writes `~/.aeolus/trierarch/config.json`, with `config.schema.json` beside it so an editor checks it. When the configuration offers Codex, it answers Codex's one-time questions ahead too, through `codex app-server` as Codex's own dialogs do: it trusts each configured repository and folder in `~/.codex/config.toml` (a repository covers its worktrees), and trusts the aeolus plugin's hooks, without which a Codex session marks no turn and is never woken. A plugin update changes the hooks: run `aeolus-trierarch init` again after updating the aeolus plugin for Codex. It answers Claude Code's one-time questions ahead, so a session nobody watches never waits on one: it trusts the worktree root in `~/.claude.json`, which covers every worktree under it, and each configured folder (on every run, so a folder added since is trusted too), and, when the sessions skip permissions, offers to accept bypass permissions mode in `~/.claude/settings.json`. Then it offers to install and start the service: a launchd agent on macOS (`~/Library/LaunchAgents/dev.aeolus-fleet.trierarch.plist`), a systemd user unit on Linux (`aeolus-trierarch.service`), started at login and again whenever it stops.
30
31
 
@@ -36,15 +37,16 @@ That gives the command `aeolus-trierarch`.
36
37
 
37
38
  | Command | What it does |
38
39
  | --- | --- |
39
- | `aeolus-trierarch status` | The service (running, pid, since), the fleet and the trierarch's own lease, the caps in use, the entries by state, kept worktrees and orphans |
40
- | `aeolus-trierarch list` | The wanted entries: ship, state, harness, workspace, since, restarts |
41
- | `aeolus-trierarch logs [--lines <n>] [--follow]` | The last lines of `~/.aeolus/trierarch/logs/trierarch.log`, and with `--follow` each new one |
42
- | `aeolus-trierarch config check` | Checks the configuration and gives the flags each harness launches with, and each option value's flags |
40
+ | `aeolus-trierarch status` | The installed version, and the one the service runs when it differs (then it says to restart), the service (running, pid, since), the fleet and the trierarch's own lease, the caps in use, the entries by state, kept worktrees and orphans |
41
+ | `aeolus-trierarch list` | The ships it crews: ship, state, harness, workspace, since, restarts |
42
+ | `aeolus-trierarch logs [--lines <n>] [--follow]` | The last lines of `~/.aeolus/trierarch/logs/trierarch.log`, and with `--follow` each new one. The log holds one JSON record per line: each action the loop takes for a ship (crew, launch, wake, report, release, confirm, forget, leave, stop) as `{ time, shipId, shipName, action, outcome, next }`, where `next` says what happens after a failure, or a message as `{ time, level, message }`. `logs` renders them as text, and `--json` gives the records as they are (a line that is no record as `{ line }`). `run` in a terminal writes the text |
43
+ | `aeolus-trierarch config check` | Checks the configuration and gives the flags each harness launches with, and each option value's flags. Then the command each harness launches on a first start and on a restart, with each flag marked `(configuration)` or `(adapter)` when the adapter adds it itself (`--no-daemon` for Codex, `--continue` on a Claude Code restart, the remote-control session name) |
43
44
  | `aeolus-trierarch start`, `stop`, `restart` | The service. `stop` returns once the trierarch has exited; a stopped one starts again at the next login. Restart it after you change the configuration |
44
45
  | `aeolus-trierarch upgrade [version]` | Installs the given version, or the latest on npm, globally and pinned to it. Then it stops the old process and starts the new one, and shows `status`. Sessions keep running: the new process takes them over. If the install fails, the old version keeps running. It never upgrades on its own |
45
- | `aeolus-trierarch install [--no-load]` | Installs the service; with `--no-load` it only writes its file |
46
+ | `aeolus-trierarch install [--no-load]` | Installs the service; over a running one it waits for the old process to exit, then loads it again. With `--no-load` it only writes its file |
46
47
  | `aeolus-trierarch uninstall` | Removes the service and stops every session. It deletes nothing else: it lists the worktrees it leaves, and keeps its own files under `~/.aeolus/trierarch/` |
47
- | `aeolus-trierarch run` | What the service runs: keeps the wanted ships crewed until stopped |
48
+ | `aeolus-trierarch run` | What the service runs: keeps the ships assigned to it crewed until stopped |
49
+ | `aeolus-trierarch --version`, `-v` | The installed version |
48
50
 
49
51
  Every command takes `--json`, so a ship can read what it says, and `--config <path>`. `status`, `list` and `logs` read what is on the machine and send no message; `status` asks the fleet `whoami` once, for the lease.
50
52
 
@@ -77,19 +79,19 @@ To stop the trierarch: `aeolus-trierarch stop`, or `aeolus-trierarch uninstall`
77
79
  }
78
80
  ```
79
81
 
80
- - **caps**: how many ships it keeps on its list, and how many sessions run at once.
81
- - **repositories**: by name. A want for a worktree of one gets a git worktree under `~/.aeolus/trierarch/worktrees/<repository>/<ship>`, detached at the want's ref or the repository's HEAD. It fetches the repository first, and a ref `origin` has a branch for checks out that remote branch (`origin/<ref>`), so a ship starts from current code; when the fetch fails it uses what the repository has. `worktreeRoot` moves that root.
82
+ - **caps**: how many ships it takes (the trierarch plugin assigns it no more), and how many sessions run at once.
83
+ - **repositories**: by name. A crew request for a worktree of one gets a git worktree under `~/.aeolus/trierarch/worktrees/<repository>/<ship>`, detached at the settings' ref or the repository's HEAD. It fetches the repository first, and a ref `origin` has a branch for checks out that remote branch (`origin/<ref>`), so a ship starts from current code; when the fetch fails it uses what the repository has. `worktreeRoot` moves that root.
82
84
  - **folders**: by name, used as they are, one ship per folder, never removed.
83
- - **harnesses**: `claude-code`, `codex` or both: the flags every launch gets, and named options. A want picks option values by name; it never adds a flag, and messages never carry paths or flags. There is no policy on which flags: put `--dangerously-skip-permissions` in `flags` if you want it. The trierarch never adds a flag by itself. With `--remote-control` and no name after it, each session is named `[<repository or folder>] <ship>`, such as `[aeolus-fleet] trial-1`, so it is easy to find among your remote-control sessions.
85
+ - **harnesses**: `claude-code`, `codex` or both: the flags every launch gets, and named options. A crew request's settings pick option values by name; they never add a flag or carry a path. There is no policy on which flags: put `--dangerously-skip-permissions` in `flags` if you want it. The trierarch never adds a flag by itself. With `--remote-control` and no name after it, each session is named `[<repository or folder>] <ship>`, such as `[aeolus-fleet] trial-1`, so it is easy to find among your remote-control sessions.
84
86
 
85
- `aeolus-trierarch init` writes caps, repositories, and Claude Code's and Codex's flags; edit the file for folders, options and `worktreeRoot`, then `aeolus-trierarch config check` and `aeolus-trierarch restart`.
87
+ `aeolus-trierarch init` writes caps, repositories, folders, and Claude Code's and Codex's flags; edit the file for options and `worktreeRoot`, then `aeolus-trierarch config check` and `aeolus-trierarch restart`.
86
88
 
87
89
  The trierarch finds the aeolus plugin in each offered harness's plugin cache (the newest version): Claude Code's under `~/.claude/plugins`, Codex's under `~/.codex/plugins` (or `$CODEX_HOME/plugins`). Set `AEOLUS_PLUGIN_ROOT` and `AEOLUS_PLUGIN_DATA` (Claude Code), or `AEOLUS_CODEX_PLUGIN_ROOT` and `AEOLUS_CODEX_PLUGIN_DATA` (Codex), to point it elsewhere. `aeolus-trierarch install` carries these, `CODEX_HOME`, `AEOLUS_TRIERARCH_CONFIG` and `PATH` into the service as they are set where it runs.
88
90
 
89
91
  ## What is here
90
92
 
91
93
  - **Core** (`src/core`), with no framework, adapter or clock of its own:
92
- - the wanted list;
94
+ - its entries, one per ship it crews, and the settings it rechecks before crewing;
93
95
  - a pure Reconciler, carried out by the run pass;
94
96
  - the restart policy: 5 s, 30 s, 2 min, then 10 min, with a budget of 5 restarts an hour;
95
97
  - the ports.
@@ -97,7 +99,7 @@ The trierarch finds the aeolus plugin in each offered harness's plugin cache (th
97
99
  - the fleet over REST;
98
100
  - tmux, on its own server (`tmux -L aeolus-trierarch`, sessions named `trierarch-<ship id>` and kept on exit). Attach to one with `tmux -L aeolus-trierarch attach -t trierarch-<ship id>`;
99
101
  - git worktrees and folders;
100
- - Claude Code and Codex, through the aeolus plugin's `aeolus-identity.sh`. A Codex session starts with `codex <prompt>`, always with `--no-daemon`, comes back with `codex resume --last`, and is woken by typing `$aeolus-wake`;
102
+ - Claude Code and Codex, through the aeolus plugin's `aeolus-identity.sh`. Each passes its prompt last, after `--`, so a prompt never reads as a flag. A Codex session starts with `codex ... -- <prompt>`, always with `--no-daemon`, comes back with `codex resume --last`, and is woken by typing `$aeolus-wake`;
101
103
  - the JSON state store.
102
104
  - **The command** (`src/cli`): `init`, `status`, `list`, `logs`, `config check`, `start`, `stop`, `restart`, `install`, `uninstall`, `run`.
103
105
  - **Adapters for the setup**: the service (launchd or systemd), Claude Code's own files and Codex's app server for their one-time questions.
@@ -1,5 +1,6 @@
1
1
  import type { TrierarchConfiguration } from '@aeolus-fleet/common';
2
- import type { HarnessPort } from '../core/ports.js';
2
+ import type { AdapterFlag, HarnessPort } from '../core/ports.js';
3
+ import { type CommandPart } from './command-line.js';
3
4
  import { type AeolusPlugin } from './plugin-identity.js';
4
5
  import type { Tmux } from './tmux.js';
5
6
  /**
@@ -10,6 +11,15 @@ import type { Tmux } from './tmux.js';
10
11
  * files.
11
12
  */
12
13
  export declare const WAKE_PROMPT = "/aeolus:wake";
14
+ export declare const CLAUDE_CODE_ADAPTER_FLAGS: readonly AdapterFlag[];
15
+ /** `claude`, the flags, `--continue` on a restart, then the prompt last after `--`: no flag takes it (`--remote-control [name]` has an optional value), and it never reads as a flag. */
16
+ export declare function claudeCodeCommandLine(at: {
17
+ flags: readonly string[];
18
+ sessionName: string;
19
+ prompt: string;
20
+ isFirstStart: boolean;
21
+ program?: string;
22
+ }): CommandPart[];
13
23
  export declare function createClaudeCodeHarness(options: {
14
24
  configuration: TrierarchConfiguration;
15
25
  plugin: AeolusPlugin;
@@ -1,3 +1,4 @@
1
+ import { partsWithWords, wordsOf } from './command-line.js';
1
2
  import { effectiveFlags } from './flags.js';
2
3
  import { createPluginIdentity } from './plugin-identity.js';
3
4
  /**
@@ -9,19 +10,36 @@ import { createPluginIdentity } from './plugin-identity.js';
9
10
  */
10
11
  export const WAKE_PROMPT = '/aeolus:wake';
11
12
  const REMOTE_CONTROL = '--remote-control';
13
+ const CONTINUE = '--continue';
14
+ const END_OF_FLAGS = '--';
15
+ export const CLAUDE_CODE_ADAPTER_FLAGS = [{ flag: CONTINUE, when: 'restart' }];
12
16
  /**
13
- * The flags, with a name for the remote-control session where the operator
14
- * gave `--remote-control` without one: `[<repository or folder>] <ship>`, so
15
- * the session is easy to find among the operator's remote-control sessions.
16
- * A name the operator gave is kept; without the flag nothing is added.
17
+ * The configured flags, with a name for the remote-control session where the
18
+ * operator gave `--remote-control` without one: `[<repository or folder>]
19
+ * <ship>`, so the session is easy to find among the operator's
20
+ * remote-control sessions. A name the operator gave is kept; without the
21
+ * flag nothing is added.
17
22
  */
18
23
  function namedRemoteControl(flags, name) {
19
24
  const at = flags.indexOf(REMOTE_CONTROL);
20
25
  const next = flags[at + 1];
21
26
  if (at === -1 || (next !== undefined && !next.startsWith('-'))) {
22
- return [...flags];
27
+ return [{ words: flags, source: 'configuration' }];
23
28
  }
24
- return [...flags.slice(0, at + 1), name, ...flags.slice(at + 1)];
29
+ return [
30
+ { words: flags.slice(0, at + 1), source: 'configuration' },
31
+ { words: [name], source: 'adapter' },
32
+ { words: flags.slice(at + 1), source: 'configuration' },
33
+ ];
34
+ }
35
+ /** `claude`, the flags, `--continue` on a restart, then the prompt last after `--`: no flag takes it (`--remote-control [name]` has an optional value), and it never reads as a flag. */
36
+ export function claudeCodeCommandLine(at) {
37
+ return partsWithWords([
38
+ { words: [at.program ?? 'claude'] },
39
+ ...namedRemoteControl(at.flags, at.sessionName),
40
+ { words: at.isFirstStart ? [] : [CONTINUE], source: 'adapter' },
41
+ { words: [END_OF_FLAGS, at.prompt] },
42
+ ]);
25
43
  }
26
44
  export function createClaudeCodeHarness(options) {
27
45
  const { configuration, plugin, sessions } = options;
@@ -33,10 +51,14 @@ export function createClaudeCodeHarness(options) {
33
51
  throw new Error(`The configuration has no harness ${harness}`);
34
52
  }
35
53
  const prompt = isFirstStart && firstPrompt !== undefined ? firstPrompt : WAKE_PROMPT;
36
- const flags = namedRemoteControl(effectiveFlags(settings, picked), `[${workspace.kind === 'worktree' ? workspace.repository : workspace.name}] ${shipName}`);
37
- // The prompt goes first: a flag with an optional value, such as `--remote-control [name]`, would take it.
38
- const command = [options.command ?? 'claude', prompt, ...flags, ...(isFirstStart ? [] : ['--continue'])];
39
- await sessions.start({ shipId, folder, command });
54
+ const command = claudeCodeCommandLine({
55
+ flags: effectiveFlags(settings, picked),
56
+ sessionName: `[${workspace.kind === 'worktree' ? workspace.repository : workspace.name}] ${shipName}`,
57
+ prompt,
58
+ isFirstStart,
59
+ ...(options.command !== undefined && { program: options.command }),
60
+ });
61
+ await sessions.start({ shipId, folder, command: wordsOf(command) });
40
62
  },
41
63
  wake: async ({ shipId }) => {
42
64
  await sessions.type({ shipId, text: WAKE_PROMPT });
@@ -1 +1 @@
1
- {"version":3,"file":"claude-code.js","sourceRoot":"","sources":["../../src/adapters/claude-code.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC5C,OAAO,EAAE,oBAAoB,EAAqB,MAAM,sBAAsB,CAAC;AAG/E;;;;;;GAMG;AAEH,MAAM,CAAC,MAAM,WAAW,GAAG,cAAc,CAAC;AAE1C,MAAM,cAAc,GAAG,kBAAkB,CAAC;AAE1C;;;;;GAKG;AACH,SAAS,kBAAkB,CAAC,KAAwB,EAAE,IAAY;IAChE,MAAM,EAAE,GAAG,KAAK,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;IACzC,MAAM,IAAI,GAAG,KAAK,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC;IAC3B,IAAI,EAAE,KAAK,CAAC,CAAC,IAAI,CAAC,IAAI,KAAK,SAAS,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC;QAC/D,OAAO,CAAC,GAAG,KAAK,CAAC,CAAC;IACpB,CAAC;IACD,OAAO,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC;AACnE,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAC,OAMvC;IACC,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,OAAO,CAAC;IAEpD,OAAO;QACL,GAAG,oBAAoB,CAAC,MAAM,CAAC;QAC/B,MAAM,EAAE,KAAK,EAAE,EAAE,MAAM,EAAE,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,CAAC,SAAS,CAAC,IAAI,KAAK,QAAQ,EAAE;gBACrG,MAAM;gBACN,YAAY;gBACZ,GAAG,CAAC,OAAO,CAAC,OAAO,KAAK,SAAS,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,OAAO,EAAE,CAAC;aACnE,CAAC,CAAC;YACH,MAAM,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC;QACtE,CAAC;QACD,IAAI,EAAE,KAAK,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE;YACzB,MAAM,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,WAAW,EAAE,CAAC,CAAC;QACrD,CAAC;KACF,CAAC;AACJ,CAAC"}
@@ -1,5 +1,6 @@
1
1
  import type { TrierarchConfiguration } from '@aeolus-fleet/common';
2
- import type { HarnessPort } from '../core/ports.js';
2
+ import type { AdapterFlag, HarnessPort } from '../core/ports.js';
3
+ import { type CommandPart } from './command-line.js';
3
4
  import { type AeolusPlugin } from './plugin-identity.js';
4
5
  import type { Tmux } from './tmux.js';
5
6
  /**
@@ -15,6 +16,14 @@ export declare const WAKE_PROMPT = "$aeolus-wake";
15
16
  * right after fast typing as part of a paste, a newline, and submits nothing.
16
17
  */
17
18
  export declare const CODEX_TYPING_SETTLE_MS = 1000;
19
+ export declare const CODEX_ADAPTER_FLAGS: readonly AdapterFlag[];
20
+ /** `codex`, or `codex resume --last` on a restart, then the configured flags, --no-daemon once, and the prompt last after `--`, so it never reads as a flag. */
21
+ export declare function codexCommandLine(at: {
22
+ flags: readonly string[];
23
+ prompt: string;
24
+ isFirstStart: boolean;
25
+ program?: string;
26
+ }): CommandPart[];
18
27
  export declare function createCodexHarness(options: {
19
28
  configuration: TrierarchConfiguration;
20
29
  plugin: AeolusPlugin;
@@ -1,3 +1,4 @@
1
+ import { partsWithWords, wordsOf } from './command-line.js';
1
2
  import { effectiveFlags } from './flags.js';
2
3
  import { createPluginIdentity } from './plugin-identity.js';
3
4
  /**
@@ -19,6 +20,18 @@ export const CODEX_TYPING_SETTLE_MS = 1000;
19
20
  * pane is gone, so a release or a crash would stop the pane but not the work.
20
21
  */
21
22
  const NO_DAEMON = '--no-daemon';
23
+ const END_OF_FLAGS = '--';
24
+ export const CODEX_ADAPTER_FLAGS = [{ flag: NO_DAEMON, when: 'always' }];
25
+ /** `codex`, or `codex resume --last` on a restart, then the configured flags, --no-daemon once, and the prompt last after `--`, so it never reads as a flag. */
26
+ export function codexCommandLine(at) {
27
+ const program = at.program ?? 'codex';
28
+ return partsWithWords([
29
+ { words: at.isFirstStart ? [program] : [program, 'resume', '--last'] },
30
+ { words: at.flags.filter((flag) => flag !== NO_DAEMON), source: 'configuration' },
31
+ { words: [NO_DAEMON], source: 'adapter' },
32
+ { words: [END_OF_FLAGS, at.prompt] },
33
+ ]);
34
+ }
22
35
  export function createCodexHarness(options) {
23
36
  const { configuration, plugin, sessions } = options;
24
37
  return {
@@ -29,10 +42,8 @@ export function createCodexHarness(options) {
29
42
  throw new Error(`The configuration has no harness ${harness}`);
30
43
  }
31
44
  const prompt = isFirstStart && firstPrompt !== undefined ? firstPrompt : WAKE_PROMPT;
32
- const program = options.command ?? 'codex';
33
- const command = isFirstStart ? [program, prompt] : [program, 'resume', '--last', prompt];
34
- const flags = effectiveFlags(settings, picked).filter((flag) => flag !== NO_DAEMON);
35
- await sessions.start({ shipId, folder, command: [...command, ...flags, NO_DAEMON] });
45
+ const command = codexCommandLine({ flags: effectiveFlags(settings, picked), prompt, isFirstStart, ...(options.command !== undefined && { program: options.command }) });
46
+ await sessions.start({ shipId, folder, command: wordsOf(command) });
36
47
  },
37
48
  wake: async ({ shipId }) => {
38
49
  // The space closes Codex's skill picker, which would otherwise take the Enter.
@@ -1 +1 @@
1
- {"version":3,"file":"codex.js","sourceRoot":"","sources":["../../src/adapters/codex.ts"],"names":[],"mappings":"AAGA,OAAO,EA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M,EAAE,OAAO,EAAE,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC;QACtE,CAAC;QACD,IAAI,EAAE,KAAK,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE;YACzB,+EAA+E;YAC/E,MAAM,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,WAAW,GAAG,EAAE,QAAQ,EAAE,sBAAsB,EAAE,CAAC,CAAC;QAC7F,CAAC;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * A harness's command line in parts, each marked by where its words come
3
+ * from: the configuration's flags, or what the adapter adds itself. The
4
+ * program and the prompt carry no source. Launch runs the words; config
5
+ * check prints the parts, so the operator sees what will launch and why.
6
+ */
7
+ export interface CommandPart {
8
+ readonly words: readonly string[];
9
+ readonly source?: 'configuration' | 'adapter';
10
+ }
11
+ export declare function wordsOf(parts: readonly CommandPart[]): string[];
12
+ /** One line: each part's words, a word with a space in quotes, and each flag part followed by its source. */
13
+ export declare function describeCommandLine(parts: readonly CommandPart[]): string;
14
+ /** The parts with words in them: a configuration with no flags adds no empty part. */
15
+ export declare function partsWithWords(parts: readonly CommandPart[]): CommandPart[];
@@ -0,0 +1,17 @@
1
+ export function wordsOf(parts) {
2
+ return parts.flatMap((part) => part.words);
3
+ }
4
+ /** One line: each part's words, a word with a space in quotes, and each flag part followed by its source. */
5
+ export function describeCommandLine(parts) {
6
+ return parts
7
+ .map((part) => {
8
+ const words = part.words.map((word) => (word.includes(' ') ? `"${word}"` : word)).join(' ');
9
+ return part.source === undefined ? words : `${words} (${part.source})`;
10
+ })
11
+ .join(' ');
12
+ }
13
+ /** The parts with words in them: a configuration with no flags adds no empty part. */
14
+ export function partsWithWords(parts) {
15
+ return parts.filter((part) => part.words.length > 0);
16
+ }
17
+ //# sourceMappingURL=command-line.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-line.js","sourceRoot":"","sources":["../../src/adapters/command-line.ts"],"names":[],"mappings":"AAWA,MAAM,UAAU,OAAO,CAAC,KAA6B;IACnD,OAAO,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAC7C,CAAC;AAED,6GAA6G;AAC7G,MAAM,UAAU,mBAAmB,CAAC,KAA6B;IAC/D,OAAO,KAAK;SACT,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;QACZ,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAC5F,OAAO,IAAI,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,KAAK,KAAK,IAAI,CAAC,MAAM,GAAG,CAAC;IACzE,CAAC,CAAC;SACD,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC;AAED,sFAAsF;AACtF,MAAM,UAAU,cAAc,CAAC,KAA6B;IAC1D,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;AACvD,CAAC"}
@@ -24,3 +24,12 @@ export declare function writeCrewFile(path: string, crew: CrewFile & {
24
24
  shipId: ShipId;
25
25
  }): Promise<void>;
26
26
  export declare function readCrewFile(path: string): Promise<CrewFile>;
27
+ /** What the running trierarch says of itself: its pid and its version, as it started. */
28
+ export interface RunningFile {
29
+ readonly pid: number;
30
+ readonly version: string;
31
+ }
32
+ /** Written by `run` as it starts: an upgrade replaces the installed files, so only the process itself knows the version it runs. */
33
+ export declare function writeRunningFile(path: string, running: RunningFile): Promise<void>;
34
+ /** None when no trierarch wrote it (one before 0.18.0 did not) or it does not fit. */
35
+ export declare function readRunningFile(path: string): Promise<RunningFile | undefined>;
@@ -67,4 +67,20 @@ export async function readCrewFile(path) {
67
67
  const shipId = idSchema('ship').safeParse(field('shipId'));
68
68
  return { fleetUrl, ...(shipId.success && { shipId: shipId.data }), crewToken };
69
69
  }
70
+ const runningFileSchema = z.object({ pid: z.int().positive(), version: z.string() });
71
+ /** Written by `run` as it starts: an upgrade replaces the installed files, so only the process itself knows the version it runs. */
72
+ export async function writeRunningFile(path, running) {
73
+ await mkdir(dirname(path), { recursive: true, mode: 0o700 });
74
+ await writeFile(path, `${JSON.stringify(running)}\n`);
75
+ }
76
+ /** None when no trierarch wrote it (one before 0.18.0 did not) or it does not fit. */
77
+ export async function readRunningFile(path) {
78
+ try {
79
+ const parsed = runningFileSchema.safeParse(JSON.parse(await readFile(path, 'utf8')));
80
+ return parsed.success ? parsed.data : undefined;
81
+ }
82
+ catch {
83
+ return undefined;
84
+ }
85
+ }
70
86
  //# sourceMappingURL=files.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"files.js","sourceRoot":"","sources":["../../src/adapters/files.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,OAAO,EAAE,QAAQ,EAAE,4BAA4B,EAA4C,MAAM,sBAAsB,CAAC;AACxH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;GAIG;AAEH,2EAA2E;AAC3E,MAAM,OAAO,kBAAmB,SAAQ,KAAK;CAAG;AAEhD,4IAA4I;AAC5I,MAAM,UAAU,oBAAoB;IAClC,OAAO;QACL,OAAO,EAAE,sBAAsB;QAC/B,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;QAC9B,YAAY,EAAE,EAAE;Q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CAAC,KAAK,UAAU,eAAe,CAAC,IAAY;IAChD,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,iBAAiB,CAAC,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC;QACrF,OAAO,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC;IAClD,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC"}
@@ -2,10 +2,10 @@ import type { TrierarchConfiguration } from '@aeolus-fleet/common';
2
2
  type HarnessConfiguration = TrierarchConfiguration['harnesses'][string];
3
3
  /**
4
4
  * The flags a launch gets: the harness's own, then each option's value as the
5
- * want picked it, or its default. A want picks names only; the flags come
5
+ * settings picked it, or its default. Settings pick names only; the flags come
6
6
  * from the configuration alone.
7
7
  */
8
8
  export declare function effectiveFlags(harness: HarnessConfiguration, options: Readonly<Record<string, string>>): string[];
9
- /** What `config check` prints: per harness, the flags a want with no options launches with, and each option's values. */
9
+ /** What `config check` prints: per harness, the flags settings with no options launch with, and each option's values. */
10
10
  export declare function describeFlags(configuration: TrierarchConfiguration): string;
11
11
  export {};
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * The flags a launch gets: the harness's own, then each option's value as the
3
- * want picked it, or its default. A want picks names only; the flags come
3
+ * settings picked it, or its default. Settings pick names only; the flags come
4
4
  * from the configuration alone.
5
5
  */
6
6
  export function effectiveFlags(harness, options) {
@@ -10,7 +10,7 @@ export function effectiveFlags(harness, options) {
10
10
  });
11
11
  return [...harness.flags, ...picked];
12
12
  }
13
- /** What `config check` prints: per harness, the flags a want with no options launches with, and each option's values. */
13
+ /** What `config check` prints: per harness, the flags settings with no options launch with, and each option's values. */
14
14
  export function describeFlags(configuration) {
15
15
  return Object.entries(configuration.harnesses)
16
16
  .map(([name, harness]) => {
@@ -4,7 +4,7 @@ import { runCommand } from './run-command.js';
4
4
  /**
5
5
  * Workspaces (docs/architecture.md, "First adapters"): a git worktree of a
6
6
  * configured repository under the worktree root, one folder per ship
7
- * (`<root>/<repository>/<ship>`), detached at the want's ref or the
7
+ * (`<root>/<repository>/<ship>`), detached at the settings' ref or the
8
8
  * repository's HEAD; or a configured folder used as it is. The repository is
9
9
  * fetched first, and a ref the remote has a branch for is that remote branch,
10
10
  * so a ship starts from current code, not from a stale local branch. A fetch