introsio 0.1.0 → 0.3.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.
- package/CHANGELOG.md +48 -1
- package/LICENSE +1 -1
- package/README.md +111 -16
- package/agents/claude.mjs +15 -8
- package/agents/codex.mjs +6 -5
- package/agents/common.mjs +55 -5
- package/agents/cursor.mjs +10 -5
- package/agents/gemini.mjs +9 -5
- package/agents/opencode.mjs +5 -4
- package/agents/vscode.mjs +9 -7
- package/agents/windsurf.mjs +1 -1
- package/cli.mjs +95 -11
- package/hook/engine.mjs +76 -3
- package/hook/features/claims.mjs +35 -2
- package/hook/features/git.mjs +43 -3
- package/hook/features/notes.mjs +2 -0
- package/hook/features/pause.mjs +340 -0
- package/hook/features/stopGuard.mjs +2 -1
- package/hook/normalize.mjs +1 -1
- package/hook/state.mjs +49 -0
- package/lib/config.mjs +1 -0
- package/lib/git.mjs +83 -5
- package/lib/jsonFile.mjs +29 -2
- package/lib/lock.mjs +144 -13
- package/lib/paths.mjs +2 -2
- package/package.json +4 -5
- package/templates/execute.md +9 -3
- package/templates/pause.md +25 -0
- package/templates/resume.md +22 -0
package/CHANGELOG.md
CHANGED
|
@@ -6,10 +6,57 @@ project uses [semantic versioning](https://semver.org/).
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.3.0]
|
|
10
|
+
|
|
11
|
+
Run `int setup` again after updating: the installed hook engine is versioned, and
|
|
12
|
+
`int doctor` reports one that is behind.
|
|
13
|
+
|
|
9
14
|
### Added
|
|
10
|
-
-
|
|
15
|
+
- `--toolset execute` for `int setup`: the slim set of 13 tools for running a plan
|
|
16
|
+
that already exists (the claim → complete loop, pause / resume and the hand-off),
|
|
17
|
+
about a third of the tool definitions an agent otherwise carries on every turn.
|
|
18
|
+
`developer` stays the default; the choice is remembered.
|
|
19
|
+
- Lost claims: when a project reset revokes a task the session holds
|
|
20
|
+
(`CLAIM_REVOKED_BY_RESET`), the hook drops the claim and tells the agent why, so
|
|
21
|
+
the stop-guard no longer holds it to work that can no longer be finished.
|
|
22
|
+
- Daily MCP budgets: when a budget is used up (`PLAN_LIMIT_REACHED`), the agent is
|
|
23
|
+
told when it resets and to pause what it holds. A refused `claimTask` leaves no
|
|
24
|
+
claim, so the agent may stop.
|
|
25
|
+
- The command procedures name finished steps in `completeTask` / `pauseTask`
|
|
26
|
+
(`completedSubtasks`) instead of one call per step, size the outcome to the task,
|
|
27
|
+
and skip chat recaps between tasks.
|
|
28
|
+
|
|
29
|
+
### Changed
|
|
30
|
+
- The push guard refuses `git push --all` and `--branches` in github mode (they
|
|
31
|
+
push the default branch too); `--tags` still passes.
|
|
32
|
+
- `bash -c` / `sh -c` / `eval` scripts are checked like the bare command, behind
|
|
33
|
+
`env` / `sudo` prefixes and nested up to 3 levels, for both the push guard and the
|
|
34
|
+
secrets check.
|
|
35
|
+
|
|
36
|
+
### Fixed
|
|
37
|
+
- Claims lost when an agent ran the hooks of parallel tool calls at the same time:
|
|
38
|
+
per-session locks now take over abandoned locks safely, a waiter saves only its own
|
|
39
|
+
changes merged into what is on disk, and atomic writes retry the rename Windows
|
|
40
|
+
refuses while a file is open.
|
|
11
41
|
|
|
12
42
|
## [0.2.0]
|
|
13
43
|
|
|
44
|
+
Never published on its own; everything in it ships in 0.3.0.
|
|
45
|
+
|
|
46
|
+
### Added
|
|
47
|
+
- `/introsio-pause` and `/introsio-resume` for every agent (`int print-pause`,
|
|
48
|
+
`int print-resume` for Windsurf): stop a task anywhere and continue it exactly,
|
|
49
|
+
in the same or another agent.
|
|
50
|
+
- Hook feature `pause`: the working tree is snapshotted under
|
|
51
|
+
`refs/introsio/paused/<taskId>` when a task is paused (nothing on a branch
|
|
52
|
+
changes), the reported git position is checked, and the repository is compared
|
|
53
|
+
with a pause before it is resumed — EXACT / DRIFT / BLOCKED. Tasks left by a
|
|
54
|
+
session that died are named as interrupted, with its workerId.
|
|
55
|
+
- `int paused [--prune]`: pauses and interrupted work on this computer, offline.
|
|
56
|
+
- The push guard refuses pushing `refs/introsio/*` in every mode.
|
|
57
|
+
- MIT license (`LICENSE`), `author`, and this changelog.
|
|
58
|
+
|
|
59
|
+
## [0.1.0]
|
|
60
|
+
|
|
14
61
|
- Global setup for Claude Code, Codex, Gemini CLI, Cursor, OpenCode, VS Code
|
|
15
62
|
and Windsurf; `/introsio-execute`; stop-guard and related hooks; `int stats`.
|
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
# int — connect any coding agent to Introsio
|
|
2
2
|
|
|
3
|
-
One command connects your coding agents to Introsio, gives them
|
|
4
|
-
`/introsio-execute`
|
|
3
|
+
One command connects your coding agents to Introsio, gives them
|
|
4
|
+
`/introsio-execute` for running a Developer Mode project, `/introsio-pause` and
|
|
5
|
+
`/introsio-resume` for stopping anywhere and continuing exactly, and installs
|
|
5
6
|
hooks that keep Introsio in step with what the agent actually did.
|
|
6
7
|
|
|
7
8
|
## Install
|
|
@@ -20,25 +21,26 @@ npm install -g introsio # keeps the `int` command (`introsio` works too)
|
|
|
20
21
|
int setup # connect your agents, once per computer
|
|
21
22
|
```
|
|
22
23
|
|
|
23
|
-
From a clone
|
|
24
|
+
From a clone, to run the code in a checkout instead of the published package (in
|
|
25
|
+
the Introsio monorepo this folder is `agent-kit/`):
|
|
24
26
|
|
|
25
27
|
```bash
|
|
26
|
-
node agent-kit/cli.mjs setup
|
|
28
|
+
node cli.mjs setup # from the monorepo root: node agent-kit/cli.mjs setup
|
|
27
29
|
```
|
|
28
30
|
|
|
29
31
|
`setup` finds the agents on this computer, or takes `--agents claude,codex,…`. It
|
|
30
32
|
installs **globally**, so it works in every repository you open, and copies the
|
|
31
33
|
hook engine to `~/.introsio/kit`, so the hooks never depend on this checkout.
|
|
32
34
|
|
|
33
|
-
| Agent | Connect (MCP) | `/introsio-execute` | Hooks |
|
|
35
|
+
| Agent | Connect (MCP) | Commands (`/introsio-execute`, `-pause`, `-resume`) | Hooks |
|
|
34
36
|
|---|---|---|---|
|
|
35
37
|
| Claude Code | `claude mcp add` (user scope) | `~/.claude/commands/` | blocking |
|
|
36
|
-
| Codex | `~/.codex/config.toml` | `/prompts:introsio-execute` | blocking |
|
|
38
|
+
| Codex | `~/.codex/config.toml` | `/prompts:introsio-execute` (and `-pause`, `-resume`) | blocking |
|
|
37
39
|
| Gemini CLI | `~/.gemini/settings.json` | `~/.gemini/commands/` | blocking |
|
|
38
40
|
| Cursor | `~/.cursor/mcp.json` | `~/.cursor/commands/` | blocking (stop-hook reliability varies by Cursor version) |
|
|
39
41
|
| OpenCode | `opencode.json` | `commands/` | blocking (a plugin) |
|
|
40
42
|
| VS Code (Copilot) | user `mcp.json` | prompt file | none |
|
|
41
|
-
| Windsurf | `mcp_config.json` | `int print-execute` → paste as
|
|
43
|
+
| Windsurf | `mcp_config.json` | `int print-execute` / `print-pause` / `print-resume` → paste as workflows | none |
|
|
42
44
|
|
|
43
45
|
**Signing in.** No key is stored anywhere. Each agent signs in through its own MCP
|
|
44
46
|
OAuth flow (Introsio supports dynamic client registration and PKCE). `setup` tells
|
|
@@ -64,6 +66,15 @@ the loop.
|
|
|
64
66
|
decision: it is let go with a visible warning and not asked again. Agents whose
|
|
65
67
|
hooks don't see MCP calls have the open set rebuilt from the transcript, read
|
|
66
68
|
incrementally.
|
|
69
|
+
- **When the server takes a task away**, the hook lets go of it and says why, so
|
|
70
|
+
the stop is never held for work nobody can finish: the task was deleted, another
|
|
71
|
+
worker holds it now, or the person reset the project's execution
|
|
72
|
+
(`CLAIM_REVOKED_BY_RESET`: that work no longer counts, so the agent leaves it and
|
|
73
|
+
claims the next).
|
|
74
|
+
- **When a daily MCP budget is used up** (`PLAN_LIMIT_REACHED`), the agent is told
|
|
75
|
+
when it resets and to pause what it holds. A refused `claimTask` leaves no claim,
|
|
76
|
+
so it may stop; pausing and completing are reporting calls the budget never
|
|
77
|
+
refuses.
|
|
67
78
|
- A hook costs **no tokens** unless it prints. The engine decides in under a
|
|
68
79
|
millisecond; one hook process, including Node start-up, takes about 50 ms.
|
|
69
80
|
`INTROSIO_HOOKS=off` turns every hook off for a session.
|
|
@@ -76,7 +87,7 @@ The hooks also include the following checks. Each one can be switched off
|
|
|
76
87
|
| `stop-guard` | No finishing while a claimed task is open |
|
|
77
88
|
| `test-gate` | `completeTask` waits for the repo's check command (`int gate set "npm test"`). Passes are cached per work tree, and a failure sends the last 40 lines back |
|
|
78
89
|
| `shipped-gate` | **local** mode: work must be committed. **github** mode: committed, pushed, off the default branch, `outcome.branch` recorded |
|
|
79
|
-
| `push-guard` | No push to the default branch, no force push, no mirror
|
|
90
|
+
| `push-guard` | No push to the default branch, no force push, no mirror, no `--all`; in local mode, no push at all. Also checked inside `bash -c` / `sh -c` / `eval` wrappers (a guard-rail, not a sandbox: script files and other interpreters are not inspected) |
|
|
80
91
|
| `secrets` | Commits and pushes adding keys, private keys or `.env` files are refused, naming the file:line, never the value |
|
|
81
92
|
| `scope` | One soft note per file edited outside the files the task names |
|
|
82
93
|
| `worker-id` | Refuses a claim with another live session's workerId, and a second claim without one |
|
|
@@ -84,6 +95,7 @@ The hooks also include the following checks. Each one can be switched off
|
|
|
84
95
|
| `lease` | One reminder when a claim is 60% through its lease with no progress reported |
|
|
85
96
|
| `reread` | Refuses once a context read the agent already has, or a schedule read straight after `nowReady` |
|
|
86
97
|
| `log` | `~/.introsio/log.jsonl`, summed up by `int stats` |
|
|
98
|
+
| `pause` | Snapshots the working tree when a task is paused, and checks the repository against a pause before it is resumed (below) |
|
|
87
99
|
|
|
88
100
|
The gates and git guards only act in sessions that have used Introsio, and only
|
|
89
101
|
on tasks that session claimed. Completing a personal task, or pushing in a repo
|
|
@@ -100,6 +112,70 @@ that has nothing to do with Introsio, is never touched.
|
|
|
100
112
|
Set a mode per repository with `int mode local`, `int mode github`,
|
|
101
113
|
`int mode off` or `int mode auto`.
|
|
102
114
|
|
|
115
|
+
## Pause and resume
|
|
116
|
+
|
|
117
|
+
Agents run out of usage, context or time in the middle of a task. Two commands
|
|
118
|
+
make that safe (ADR-0011 in the Introsio repository):
|
|
119
|
+
|
|
120
|
+
```
|
|
121
|
+
/introsio-pause [--release] [note] # in the agent, before it stops
|
|
122
|
+
/introsio-resume [task id | project] # in any agent, any time later
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
int paused # in a terminal: what is paused or interrupted on this computer
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
**Pause** settles the subtasks, then calls `pauseTask` with a note written for
|
|
130
|
+
someone with none of the conversation, the next steps, the subtask it was on and
|
|
131
|
+
the git position. Introsio keeps the task in progress, ends the lease, and never
|
|
132
|
+
hands it to another worker automatically. At that moment the hook saves the whole
|
|
133
|
+
working tree (tracked changes and untracked files) as a commit under
|
|
134
|
+
`refs/introsio/paused/<taskId>`: your branch, files, index and stash are not
|
|
135
|
+
touched, and the ref is never pushed. It also checks the branch and commit the
|
|
136
|
+
agent reports against the real ones. `--release` commits (and in github mode
|
|
137
|
+
pushes) the work first and hands the task to any worker.
|
|
138
|
+
|
|
139
|
+
**Resume** reads the pause without claiming the task, and the hook compares the
|
|
140
|
+
repository with it, in code, and answers:
|
|
141
|
+
|
|
142
|
+
| Verdict | Means | The agent then |
|
|
143
|
+
|---|---|---|
|
|
144
|
+
| **EXACT** | same repository, branch, HEAD and working tree as the pause | takes the task back (`claimTask { taskId, resume: true }`) and continues from the note |
|
|
145
|
+
| **DRIFT** | something moved: other branch, new commits (listed with authors), HEAD behind, rewritten history, files changed since the pause, the unfinished work wiped (with the exact `git restore` command from the snapshot), the task edited | shows you the differences and asks: restore, continue as it is, or leave it paused |
|
|
146
|
+
| **BLOCKED** | wrong repository, a merge/rebase half done, the unfinished code only on another computer, another live session on the task | does not resume, and says why |
|
|
147
|
+
|
|
148
|
+
If an agent died without pausing, resume names the task as **interrupted**, with
|
|
149
|
+
the dead session's workerId, so it is taken over at once instead of waiting for
|
|
150
|
+
the lease to expire. Completing the task removes its snapshot;
|
|
151
|
+
`int paused --prune [--days 30]` removes old ones.
|
|
152
|
+
|
|
153
|
+
| # | Case | What happens |
|
|
154
|
+
|---|---|---|
|
|
155
|
+
| P1 | Usage cut off before any pause | The task shows as interrupted (local session dead); resume takes it over with that workerId |
|
|
156
|
+
| P2 | Cut off between the snapshot and `pauseTask` | No ref is kept (written only after the pause lands); resume treats it as P1 |
|
|
157
|
+
| P3 | Two resumes of one pause | Compare-and-swap on the pause: the second is refused, naming who resumed it |
|
|
158
|
+
| P4 | A worker that does not hold the task pauses it | Refused (409) |
|
|
159
|
+
| P5 | The lease ran out before the pause | Allowed while nobody else took the task |
|
|
160
|
+
| P6 | Someone took the task after the lease ran out | Refused, and the hook drops the claim (R16) |
|
|
161
|
+
| P7 | Other workers looking for work | A paused task is never handed out; `reason: "paused"` when only paused work is left; resuming a task another live session is working is BLOCKED |
|
|
162
|
+
| P8 | `--release` | Refused while the task's files are uncommitted; once committed, any worker gets the task and the note |
|
|
163
|
+
| P9 | Completed, blocked or personal tasks | Cannot be paused |
|
|
164
|
+
| P10 | Branch switched, commits added, reset back, rebased or force-pushed | DRIFT with each difference named |
|
|
165
|
+
| P11 | Working tree reset or cleaned | DRIFT with the exact `git restore --source=<snapshot>` command, run only after you agree |
|
|
166
|
+
| P12 | Untracked and ignored files | Untracked files are in the snapshot; ignored files never are |
|
|
167
|
+
| P13 | Not a git repository, detached HEAD, merge or rebase half done | Paused without a snapshot / recorded as no branch / resume BLOCKED until it is finished |
|
|
168
|
+
| P14 | A snapshot that takes too long (huge tree) | The pause goes through without one, and says so; resume compares file lists |
|
|
169
|
+
| P15 | Secrets | Only paths and commit ids go to Introsio; `refs/introsio/*` can never be pushed |
|
|
170
|
+
| P16 | The task was edited while paused | Resume says to re-read it before coding |
|
|
171
|
+
| P17 | Several tasks held, one paused | The others still hold the stop |
|
|
172
|
+
| P18 | Windows / macOS path spellings | One repository key (R24) |
|
|
173
|
+
| P19 | Agents without hooks (VS Code, Windsurf) | The commands list the same checks to run by hand |
|
|
174
|
+
| P20 | Completed, undone, released or moved out of in-progress in the app | The pause ends; completing removes the snapshot and local record |
|
|
175
|
+
|
|
176
|
+
Tests: `test/pause.test.js` (real git repositories, the real hook script), and the
|
|
177
|
+
server's `backend-node/src/tests/agentPause.test.js`.
|
|
178
|
+
|
|
103
179
|
## Edge cases (researched, reproduced, fixed)
|
|
104
180
|
|
|
105
181
|
Each of these was first reproduced against the earlier kit, then fixed, and is kept
|
|
@@ -107,7 +183,7 @@ as a regression test in `test/edgecases.test.js` (same numbers).
|
|
|
107
183
|
|
|
108
184
|
| # | What broke | What the kit does now |
|
|
109
185
|
|---|---|---|
|
|
110
|
-
| R1 | Agents run the hooks of parallel tool calls at the same time; concurrent writes lost claims (10 of 12 kept) | Every session update runs under a per-session lock (`lib/lock.mjs
|
|
186
|
+
| R1 | Agents run the hooks of parallel tool calls at the same time; concurrent writes lost claims (10 of 12 kept) | Every session update runs under a per-session lock (`lib/lock.mjs`): the holder's pid is in the lock; an abandoned lock (owner gone, after a 2 s grace — on Windows a released lock lingers while another process has it open) is taken over through a guard that re-checks it, a live holder's only after 60 s; release retries Windows' transient errors. A waiter goes on unlocked after 6 s and then saves only its own changes, merged into what is on disk (`mergeSessionChanges`, under the lock again). Atomic writes retry a rename Windows refuses while the file is open (`lib/jsonFile.mjs`) |
|
|
111
187
|
| R2 | A timed-out test gate left its child processes (test workers) running | The gate runs in its own process group; on timeout, on exit, or if the agent kills the hook, the whole group is killed (`lib/processTree.mjs`) |
|
|
112
188
|
| R3 | A diff over 16 MB made the gate cache blind to changes, so stale passes were reused | The cache key is the `git stash create` tree id plus every untracked file's size/mtime; an unreadable tree is never cached |
|
|
113
189
|
| R4 | A bare `git push` from a branch whose upstream is main went through | A bare push is checked against `@{push}` (honours `push.default`) |
|
|
@@ -131,6 +207,8 @@ as a regression test in `test/edgecases.test.js` (same numbers).
|
|
|
131
207
|
| R22 | A hand-broken settings file was silently replaced by the next command | Commands refuse to write a settings file they cannot read; hooks keep running on defaults |
|
|
132
208
|
| R23 | Internal hook errors vanished | They go to `~/.introsio/errors.log` (1 MB, rotated); `int doctor` shows recent ones; the agent still gets valid output |
|
|
133
209
|
| R24 | On Windows, git (`C:/…`), Node (`C:\…`) and temp folders (`MAHESH~1`) spell one folder three ways, so `int mode` / `int gate` settings were never found by the hooks and edited files looked "outside" the repo (found on the first Windows run) | One canonical spelling (`canonicalPath` / `repoKey` in `lib/paths.mjs`, case-insensitive on Windows) for every settings key and file comparison; CI now runs on Windows, macOS and Linux |
|
|
210
|
+
| R25 | `git push --all origin` went through: the guard skipped `--all`, which pushes every local branch, the default one included | `--all` / `--branches` are refused in github mode; `--tags` still passes |
|
|
211
|
+
| R26 | `bash -c "git push origin main"` (or a wrapped commit of a key) went through: the quoted script was one word with no `git` in it | `sh`/`bash`/`zsh`/`dash`/`ksh -c` and `eval` scripts are checked like the bare command (behind `env`/`sudo` prefixes, nested up to 3 levels) for both the push guard and the secrets check |
|
|
134
212
|
|
|
135
213
|
Tested end to end with Claude Code 2.1.312 (headless `claude -p`, a stub Introsio
|
|
136
214
|
MCP server over stdio, the installed hooks):
|
|
@@ -142,20 +220,27 @@ MCP server over stdio, the installed hooks):
|
|
|
142
220
|
## Commands
|
|
143
221
|
|
|
144
222
|
```
|
|
145
|
-
int setup [--agents a,b] [--project <repo>] [--url <mcp url>] [--dry-run]
|
|
223
|
+
int setup [--agents a,b] [--project <repo>] [--toolset developer|execute|all] [--url <mcp url>] [--dry-run]
|
|
146
224
|
int uninstall [--agents a,b] [--project <repo>]
|
|
147
225
|
int status | doctor
|
|
148
226
|
int mode github|local|off|auto
|
|
149
227
|
int gate set "<cmd>" [--timeout <sec>] | gate off | gate run | gate
|
|
150
228
|
int features | enable <name> | disable <name>
|
|
151
229
|
int claims | claims clear
|
|
230
|
+
int paused [--prune [--days 30]]
|
|
152
231
|
int stats [--since 7d] [--project <id>] [--json]
|
|
153
|
-
int print-execute
|
|
232
|
+
int print-execute | print-pause | print-resume
|
|
154
233
|
```
|
|
155
234
|
|
|
156
235
|
- `--project <repo>` installs into one repository instead (committed, so a team
|
|
157
236
|
shares it). The kit is copied to `<repo>/.introsio/kit` and the configs use
|
|
158
237
|
repo-relative paths.
|
|
238
|
+
- `--toolset` chooses which Introsio tools the agents load, and is remembered.
|
|
239
|
+
`developer` (the default) plans and executes. `execute` is the slim set for
|
|
240
|
+
running a plan that already exists — the 13 tools of the claim → complete loop,
|
|
241
|
+
pause / resume and the hand-off, about a third of the tool definitions an agent
|
|
242
|
+
carries on every turn. It cannot create or edit a plan; switch back with
|
|
243
|
+
`int setup --toolset developer`.
|
|
159
244
|
- `--url` points the agents at another MCP server, such as a local backend; it is
|
|
160
245
|
remembered.
|
|
161
246
|
- A config file with comments is never rewritten. `setup` prints what to add to it.
|
|
@@ -168,9 +253,9 @@ int print-execute
|
|
|
168
253
|
- `hook/introsio-hook.mjs` → `normalize.mjs` (each agent's payload into one shape) → `engine.mjs` (the decisions) → `respond.mjs` (each agent's output format)
|
|
169
254
|
- `hook/features/*.mjs` — one pure module per feature
|
|
170
255
|
- `opencode/introsio.template.js` — the OpenCode plugin (it imports the same engine)
|
|
171
|
-
- `templates/execute.md` — the
|
|
256
|
+
- `templates/execute.md`, `pause.md`, `resume.md` — the three command procedures, rendered into each agent's command format
|
|
172
257
|
|
|
173
|
-
Tests: `npm
|
|
258
|
+
Tests: `npm test` in this folder. They use plain
|
|
174
259
|
`node:assert/strict`, a scratch HOME and real git repositories.
|
|
175
260
|
|
|
176
261
|
Hook formats follow each agent's documentation as of October 2026. Agents change
|
|
@@ -180,17 +265,27 @@ these often: run `int doctor` after updating an agent.
|
|
|
180
265
|
|
|
181
266
|
The package is `introsio` on npm (commands `int` and `introsio`).
|
|
182
267
|
|
|
183
|
-
1. Bump `version` in `package.json` (`int doctor` tells users on older hooks to re-run `int setup`), and merge.
|
|
268
|
+
1. Bump `version` in `package.json` and describe the release in `CHANGELOG.md` (`int doctor` tells users on older hooks to re-run `int setup`), and merge.
|
|
184
269
|
2. Add the repository secret `NPM_TOKEN` once (an npm Automation token that may publish `introsio`).
|
|
185
270
|
3. Tag the release; `.github/workflows/agent-kit-release.yml` runs the tests, checks the tag against the version, and publishes with provenance:
|
|
186
271
|
|
|
187
272
|
```bash
|
|
188
|
-
git tag agent-kit-v0.
|
|
273
|
+
git tag agent-kit-v0.3.0 && git push origin agent-kit-v0.3.0
|
|
189
274
|
```
|
|
190
275
|
|
|
191
276
|
To publish by hand instead: `npm login`, then `npm publish` from this folder (the tests run first via `prepublishOnly`).
|
|
192
277
|
|
|
278
|
+
The code is edited only in the Introsio monorepo's `agent-kit/` folder. The
|
|
279
|
+
standalone [Introsio-cli](https://github.com/introsio/Introsio-cli) repository is
|
|
280
|
+
a mirror of that folder, updated from the monorepo root (never edited directly):
|
|
281
|
+
|
|
282
|
+
```bash
|
|
283
|
+
git fetch cli
|
|
284
|
+
git subtree split --prefix=agent-kit -b cli-only
|
|
285
|
+
git push cli cli-only:main
|
|
286
|
+
```
|
|
287
|
+
|
|
193
288
|
## License
|
|
194
289
|
|
|
195
|
-
[MIT](./LICENSE) ©
|
|
290
|
+
[MIT](./LICENSE) © 2026 Introsio. This license covers the `int` CLI in
|
|
196
291
|
`agent-kit/` only; the Introsio service it connects to is a separate product.
|
package/agents/claude.mjs
CHANGED
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
// Claude Code: MCP via `claude mcp add` (or ~/.claude.json / .mcp.json), /introsio-execute as a command, hooks in settings.json.
|
|
2
|
-
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand, markdownCommand,
|
|
2
|
+
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand, markdownCommand, writeCommands, removeCommands, commandsStatus, existsDir, hasCli, SERVER_NAME, COMMAND_NAME } from './common.mjs';
|
|
3
3
|
import { readJsonSafe } from '../lib/jsonFile.mjs';
|
|
4
4
|
|
|
5
|
-
const paths = (ctx) =>
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
const paths = (ctx) => {
|
|
6
|
+
const base = ctx.scope === 'project' ? ctx.root : ctx.home;
|
|
7
|
+
const commandFile = (name) => join(base, '.claude', 'commands', `${name}.md`);
|
|
8
|
+
return {
|
|
9
|
+
settings: join(base, '.claude', 'settings.json'),
|
|
10
|
+
mcp: ctx.scope === 'project' ? join(ctx.root, '.mcp.json') : join(ctx.home, '.claude.json'),
|
|
11
|
+
command: commandFile(COMMAND_NAME),
|
|
12
|
+
commandFile,
|
|
13
|
+
};
|
|
14
|
+
};
|
|
8
15
|
|
|
9
16
|
function hookGroups(ctx) {
|
|
10
17
|
const cmd = (event, timeout) => ({ type: 'command', command: hookCommand(ctx, 'claude', event), timeout });
|
|
@@ -47,8 +54,8 @@ export default {
|
|
|
47
54
|
});
|
|
48
55
|
report.connect = result.error ?? (result.manual ? `manual — add "${SERVER_NAME}": { "type": "http", "url": "${ctx.url}" } to mcpServers in ${p.mcp}` : result.changed ? 'added' : 'already connected');
|
|
49
56
|
}
|
|
50
|
-
report.next.push('In Claude Code run /mcp, pick "introsio" and sign in. Then: /introsio-execute <project>');
|
|
51
|
-
writer
|
|
57
|
+
report.next.push('In Claude Code run /mcp, pick "introsio" and sign in. Then: /introsio-execute <project> — /introsio-pause before you stop, /introsio-resume to continue');
|
|
58
|
+
writeCommands(writer, p.commandFile, (command) => markdownCommand(ctx, { command, argumentHint: true }));
|
|
52
59
|
const hooks = editJson(writer, p.settings, (settings) => setMatcherHooks(settings, hookGroups(ctx)));
|
|
53
60
|
if (hooks.manual || hooks.error) report.hooks = hooks.error ?? `manual — ${p.settings} has comments; add the hooks shown by \`int setup --print claude\``;
|
|
54
61
|
return report;
|
|
@@ -58,14 +65,14 @@ export default {
|
|
|
58
65
|
if (ctx.scope === 'user' && hasCli('claude', ctx.env)) writer.run('claude', ['mcp', 'remove', '--scope', 'user', SERVER_NAME]);
|
|
59
66
|
else editJson(writer, p.mcp, (config) => (config.mcpServers?.[SERVER_NAME] ? (delete config.mcpServers[SERVER_NAME], true) : false));
|
|
60
67
|
editJson(writer, p.settings, (settings) => removeMatcherHooks(settings));
|
|
61
|
-
writer
|
|
68
|
+
removeCommands(writer, p.commandFile);
|
|
62
69
|
},
|
|
63
70
|
status(ctx) {
|
|
64
71
|
const p = paths(ctx);
|
|
65
72
|
const mcp = readJsonSafe(p.mcp, {});
|
|
66
73
|
return {
|
|
67
74
|
connect: mcp.mcpServers?.[SERVER_NAME] ? 'yes' : (ctx.scope === 'user' ? 'see `claude mcp list`' : 'no'),
|
|
68
|
-
command:
|
|
75
|
+
command: commandsStatus(p.commandFile),
|
|
69
76
|
hooks: hasOurHooks(readJsonSafe(p.settings, {})) ? 'blocking' : 'not installed',
|
|
70
77
|
};
|
|
71
78
|
},
|
package/agents/codex.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Codex: MCP server in config.toml (a managed block), /prompts:introsio-execute, hooks in hooks.json.
|
|
2
|
-
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand, markdownCommand,
|
|
2
|
+
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand, markdownCommand, writeCommands, removeCommands, commandsStatus, existsDir, hasCli, SERVER_NAME, COMMAND_NAME } from './common.mjs';
|
|
3
3
|
import { readJsonSafe, readText } from '../lib/jsonFile.mjs';
|
|
4
4
|
import { withBlock, withoutBlock, hasBlock } from '../lib/managedBlock.mjs';
|
|
5
5
|
|
|
@@ -8,6 +8,7 @@ const paths = (ctx) => ({
|
|
|
8
8
|
config: join(base(ctx), 'config.toml'),
|
|
9
9
|
hooks: join(base(ctx), 'hooks.json'),
|
|
10
10
|
command: join(base(ctx), 'prompts', `${COMMAND_NAME}.md`),
|
|
11
|
+
commandFile: (name) => join(base(ctx), 'prompts', `${name}.md`),
|
|
11
12
|
});
|
|
12
13
|
|
|
13
14
|
function hookGroups(ctx) {
|
|
@@ -39,9 +40,9 @@ export default {
|
|
|
39
40
|
const body = `[mcp_servers.${SERVER_NAME}]\nurl = ${JSON.stringify(ctx.url)}`;
|
|
40
41
|
report.connect = writer.writeText(p.config, withBlock(text, body)) ? 'added' : 'already connected';
|
|
41
42
|
}
|
|
42
|
-
report.next.push(`Sign in: codex mcp login ${SERVER_NAME}. Then in Codex: /prompts:${COMMAND_NAME} <project
|
|
43
|
+
report.next.push(`Sign in: codex mcp login ${SERVER_NAME}. Then in Codex: /prompts:${COMMAND_NAME} <project> (also /prompts:introsio-pause and /prompts:introsio-resume)`);
|
|
43
44
|
report.next.push('If your Codex version keeps hooks behind a flag, add to config.toml: [features] codex_hooks = true');
|
|
44
|
-
writer
|
|
45
|
+
writeCommands(writer, p.commandFile, (command) => markdownCommand(ctx, { command, argumentHint: true }));
|
|
45
46
|
const hooks = editJson(writer, p.hooks, (config) => setMatcherHooks(config, hookGroups(ctx)));
|
|
46
47
|
if (hooks.manual || hooks.error) report.hooks = hooks.error ?? `manual — ${p.hooks} has comments`;
|
|
47
48
|
return report;
|
|
@@ -51,14 +52,14 @@ export default {
|
|
|
51
52
|
const text = readText(p.config);
|
|
52
53
|
if (text && hasBlock(text)) writer.writeText(p.config, withoutBlock(text));
|
|
53
54
|
editJson(writer, p.hooks, (config) => removeMatcherHooks(config));
|
|
54
|
-
writer
|
|
55
|
+
removeCommands(writer, p.commandFile);
|
|
55
56
|
},
|
|
56
57
|
status(ctx) {
|
|
57
58
|
const p = paths(ctx);
|
|
58
59
|
const text = readText(p.config) ?? '';
|
|
59
60
|
return {
|
|
60
61
|
connect: hasBlock(text) || userDefinedServer(text) ? 'yes' : 'no',
|
|
61
|
-
command:
|
|
62
|
+
command: commandsStatus(p.commandFile),
|
|
62
63
|
hooks: hasOurHooks(readJsonSafe(p.hooks, {})) ? 'blocking' : 'not installed',
|
|
63
64
|
};
|
|
64
65
|
},
|
package/agents/common.mjs
CHANGED
|
@@ -9,6 +9,28 @@ export const COMMAND_NAME = 'introsio-execute';
|
|
|
9
9
|
export const HOOK_MARK = 'introsio-hook.mjs';
|
|
10
10
|
export const DESCRIPTION = 'Execute an Introsio Developer Mode project task by task (claim → work → complete)';
|
|
11
11
|
|
|
12
|
+
/**
|
|
13
|
+
* The commands every agent gets. `template` is a file in templates/; `$ARGUMENTS`
|
|
14
|
+
* in it is rendered the way each agent passes what the user typed after the command.
|
|
15
|
+
*/
|
|
16
|
+
export const COMMANDS = Object.freeze([
|
|
17
|
+
{ name: COMMAND_NAME, template: 'execute.md', description: DESCRIPTION, argumentHint: '<project name or id>', inputLabel: 'Project name or id' },
|
|
18
|
+
{
|
|
19
|
+
name: 'introsio-pause',
|
|
20
|
+
template: 'pause.md',
|
|
21
|
+
description: 'Pause the Introsio task(s) you hold so they resume exactly later — note, next steps, git snapshot (out of usage, context or time)',
|
|
22
|
+
argumentHint: '[--release] [anything the next session should know]',
|
|
23
|
+
inputLabel: 'Optional: --release, and a note',
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
name: 'introsio-resume',
|
|
27
|
+
template: 'resume.md',
|
|
28
|
+
description: 'Resume paused or interrupted Introsio work exactly where it stopped — after checking the repository still matches',
|
|
29
|
+
argumentHint: '[task id, or project name or id]',
|
|
30
|
+
inputLabel: 'Optional: task id or project',
|
|
31
|
+
},
|
|
32
|
+
]);
|
|
33
|
+
|
|
12
34
|
export class Writer {
|
|
13
35
|
constructor({ dryRun = false } = {}) {
|
|
14
36
|
this.dryRun = dryRun;
|
|
@@ -127,14 +149,42 @@ export function nodePathOf(command) {
|
|
|
127
149
|
return match ? match[1] : '';
|
|
128
150
|
}
|
|
129
151
|
|
|
130
|
-
/**
|
|
152
|
+
/** A command's procedure, with `$ARGUMENTS` rendered the way an agent's commands expect. */
|
|
153
|
+
export function commandText(ctx, command = COMMANDS[0], argumentToken = '$ARGUMENTS') {
|
|
154
|
+
const template = ctx.templates?.[command.name] ?? (command.name === COMMAND_NAME ? ctx.executeTemplate : '');
|
|
155
|
+
return String(template ?? '').replaceAll('$ARGUMENTS', argumentToken).trim();
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/** The execute procedure (kept for callers that only know that one). */
|
|
131
159
|
export function executeText(ctx, argumentToken = '$ARGUMENTS') {
|
|
132
|
-
return ctx
|
|
160
|
+
return commandText(ctx, COMMANDS[0], argumentToken);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/** A Markdown command file: frontmatter, then the procedure. `argumentHint: true` adds each command's own hint. */
|
|
164
|
+
export function markdownCommand(ctx, { command = COMMANDS[0], frontmatter = {}, argumentToken, argumentHint = false } = {}) {
|
|
165
|
+
const fields = { description: command.description, ...(argumentHint ? { 'argument-hint': command.argumentHint } : {}), ...frontmatter };
|
|
166
|
+
const lines = Object.entries(fields).map(([key, value]) => `${key}: ${value}`);
|
|
167
|
+
return `---\n${lines.join('\n')}\n---\n\n${commandText(ctx, command, argumentToken)}\n`;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
/** Writes one file per command (`fileFor(name)` → path); returns the paths. */
|
|
171
|
+
export function writeCommands(writer, fileFor, render) {
|
|
172
|
+
return COMMANDS.map((command) => {
|
|
173
|
+
const file = fileFor(command.name);
|
|
174
|
+
writer.writeText(file, render(command));
|
|
175
|
+
return file;
|
|
176
|
+
});
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
export function removeCommands(writer, fileFor) {
|
|
180
|
+
for (const command of COMMANDS) writer.remove(fileFor(command.name));
|
|
133
181
|
}
|
|
134
182
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
183
|
+
/** "yes" when every command file is there, "partial — re-run int setup" when some are, "no" otherwise. */
|
|
184
|
+
export function commandsStatus(fileFor) {
|
|
185
|
+
const present = COMMANDS.filter((command) => fs.existsSync(fileFor(command.name))).length;
|
|
186
|
+
if (present === COMMANDS.length) return 'yes';
|
|
187
|
+
return present === 0 ? 'no' : 'partial — re-run int setup';
|
|
138
188
|
}
|
|
139
189
|
|
|
140
190
|
export function existsDir(dir) {
|
package/agents/cursor.mjs
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
// Cursor: MCP in mcp.json, /introsio-execute in commands/, hooks in hooks.json (version 1 format).
|
|
2
|
-
import { join, editJson, hookCommand, markdownCommand,
|
|
2
|
+
import { join, editJson, hookCommand, markdownCommand, writeCommands, removeCommands, commandsStatus, existsDir, SERVER_NAME, COMMAND_NAME, HOOK_MARK } from './common.mjs';
|
|
3
3
|
import { readJsonSafe } from '../lib/jsonFile.mjs';
|
|
4
4
|
|
|
5
5
|
const base = (ctx) => (ctx.scope === 'project' ? join(ctx.root, '.cursor') : join(ctx.home, '.cursor'));
|
|
6
|
-
const paths = (ctx) => ({
|
|
6
|
+
const paths = (ctx) => ({
|
|
7
|
+
mcp: join(base(ctx), 'mcp.json'),
|
|
8
|
+
hooks: join(base(ctx), 'hooks.json'),
|
|
9
|
+
command: join(base(ctx), 'commands', `${COMMAND_NAME}.md`),
|
|
10
|
+
commandFile: (name) => join(base(ctx), 'commands', `${name}.md`),
|
|
11
|
+
});
|
|
7
12
|
|
|
8
13
|
const EVENTS = ['beforeMCPExecution', 'afterMCPExecution', 'beforeShellExecution', 'afterFileEdit', 'stop'];
|
|
9
14
|
|
|
@@ -36,7 +41,7 @@ export default {
|
|
|
36
41
|
});
|
|
37
42
|
report.connect = mcp.error ?? (mcp.manual ? `manual — add "${SERVER_NAME}": { "url": "${ctx.url}" } to ${p.mcp}` : mcp.changed ? 'added' : 'already connected');
|
|
38
43
|
report.next.push('In Cursor: Settings → MCP → introsio → Connect (sign in). Then in Agent chat: /introsio-execute <project>');
|
|
39
|
-
writer
|
|
44
|
+
writeCommands(writer, p.commandFile, (command) => markdownCommand(ctx, { command, argumentToken: 'what the user wrote after the command' }));
|
|
40
45
|
const hooks = editJson(writer, p.hooks, (config) => {
|
|
41
46
|
config.version = config.version ?? 1;
|
|
42
47
|
config.hooks = config.hooks ?? {};
|
|
@@ -51,12 +56,12 @@ export default {
|
|
|
51
56
|
const p = paths(ctx);
|
|
52
57
|
editJson(writer, p.mcp, (config) => (config.mcpServers?.[SERVER_NAME] ? (delete config.mcpServers[SERVER_NAME], true) : false));
|
|
53
58
|
editJson(writer, p.hooks, (config) => removeOurs(config));
|
|
54
|
-
writer
|
|
59
|
+
removeCommands(writer, p.commandFile);
|
|
55
60
|
},
|
|
56
61
|
status(ctx) {
|
|
57
62
|
const p = paths(ctx);
|
|
58
63
|
const hooks = JSON.stringify(readJsonSafe(p.hooks, {}));
|
|
59
|
-
return { connect: readJsonSafe(p.mcp, {}).mcpServers?.[SERVER_NAME] ? 'yes' : 'no', command:
|
|
64
|
+
return { connect: readJsonSafe(p.mcp, {}).mcpServers?.[SERVER_NAME] ? 'yes' : 'no', command: commandsStatus(p.commandFile), hooks: hooks.includes(HOOK_MARK) ? 'blocking' : 'not installed' };
|
|
60
65
|
},
|
|
61
66
|
print: (ctx) => ({ version: 1, hooks: Object.fromEntries(EVENTS.map((event) => [event, [{ command: hookCommand(ctx, 'cursor', event) }]])) }),
|
|
62
67
|
};
|
package/agents/gemini.mjs
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
// Gemini CLI: MCP + hooks in settings.json, /introsio-execute as a TOML command.
|
|
2
|
-
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand,
|
|
2
|
+
import { join, editJson, setMatcherHooks, removeMatcherHooks, hasOurHooks, hookCommand, commandText, writeCommands, removeCommands, commandsStatus, existsDir, hasCli, SERVER_NAME, COMMAND_NAME } from './common.mjs';
|
|
3
3
|
import { readJsonSafe } from '../lib/jsonFile.mjs';
|
|
4
4
|
|
|
5
5
|
const base = (ctx) => (ctx.scope === 'project' ? join(ctx.root, '.gemini') : join(ctx.home, '.gemini'));
|
|
6
|
-
const paths = (ctx) => ({
|
|
6
|
+
const paths = (ctx) => ({
|
|
7
|
+
settings: join(base(ctx), 'settings.json'),
|
|
8
|
+
command: join(base(ctx), 'commands', `${COMMAND_NAME}.toml`),
|
|
9
|
+
commandFile: (name) => join(base(ctx), 'commands', `${name}.toml`),
|
|
10
|
+
});
|
|
7
11
|
|
|
8
12
|
function hookGroups(ctx) {
|
|
9
13
|
// Gemini timeouts are milliseconds.
|
|
@@ -38,7 +42,7 @@ export default {
|
|
|
38
42
|
report.connect = result.error ?? (result.manual ? `manual — ${p.settings} has comments; add mcpServers.${SERVER_NAME} = { "httpUrl": "${ctx.url}" }` : 'added');
|
|
39
43
|
if (result.manual || result.error) report.hooks = 'manual';
|
|
40
44
|
report.next.push(`In Gemini CLI run /mcp auth ${SERVER_NAME} to sign in. Then: /${COMMAND_NAME} <project>`);
|
|
41
|
-
writer
|
|
45
|
+
writeCommands(writer, p.commandFile, (command) => `description = ${JSON.stringify(command.description)}\nprompt = ${tomlString(commandText(ctx, command, '{{args}}'))}\n`);
|
|
42
46
|
return report;
|
|
43
47
|
},
|
|
44
48
|
uninstall(ctx, writer) {
|
|
@@ -48,12 +52,12 @@ export default {
|
|
|
48
52
|
if (had) delete settings.mcpServers[SERVER_NAME];
|
|
49
53
|
return removeMatcherHooks(settings) || had;
|
|
50
54
|
});
|
|
51
|
-
writer
|
|
55
|
+
removeCommands(writer, p.commandFile);
|
|
52
56
|
},
|
|
53
57
|
status(ctx) {
|
|
54
58
|
const p = paths(ctx);
|
|
55
59
|
const settings = readJsonSafe(p.settings, {});
|
|
56
|
-
return { connect: settings.mcpServers?.[SERVER_NAME] ? 'yes' : 'no', command:
|
|
60
|
+
return { connect: settings.mcpServers?.[SERVER_NAME] ? 'yes' : 'no', command: commandsStatus(p.commandFile), hooks: hasOurHooks(settings) ? 'blocking' : 'not installed' };
|
|
57
61
|
},
|
|
58
62
|
print: (ctx) => ({ hooks: hookGroups(ctx) }),
|
|
59
63
|
};
|
package/agents/opencode.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// OpenCode: MCP in opencode.json, /introsio-execute in commands/, and a plugin (OpenCode has no shell hooks).
|
|
2
2
|
import path from 'node:path';
|
|
3
3
|
import { pathToFileURL } from 'node:url';
|
|
4
|
-
import { join, editJson, markdownCommand, existsDir, existsFile, hasCli, SERVER_NAME, COMMAND_NAME } from './common.mjs';
|
|
4
|
+
import { join, editJson, markdownCommand, writeCommands, removeCommands, commandsStatus, existsDir, existsFile, hasCli, SERVER_NAME, COMMAND_NAME } from './common.mjs';
|
|
5
5
|
import { readJsonSafe, readText } from '../lib/jsonFile.mjs';
|
|
6
6
|
import { xdgConfigHome } from '../lib/paths.mjs';
|
|
7
7
|
|
|
@@ -10,6 +10,7 @@ const paths = (ctx) => {
|
|
|
10
10
|
return {
|
|
11
11
|
config: ctx.scope === 'project' ? join(ctx.root, 'opencode.json') : join(base, 'opencode.json'),
|
|
12
12
|
command: join(base, 'commands', `${COMMAND_NAME}.md`),
|
|
13
|
+
commandFile: (name) => join(base, 'commands', `${name}.md`),
|
|
13
14
|
plugin: join(base, 'plugins', 'introsio.js'),
|
|
14
15
|
};
|
|
15
16
|
};
|
|
@@ -43,21 +44,21 @@ export default {
|
|
|
43
44
|
});
|
|
44
45
|
report.connect = config.error ?? (config.manual ? `manual — add "mcp": { "${SERVER_NAME}": { "type": "remote", "url": "${ctx.url}" } } to ${p.config}` : config.changed ? 'added' : 'already connected');
|
|
45
46
|
report.next.push(`Sign in: opencode mcp auth ${SERVER_NAME}. Then in OpenCode: /${COMMAND_NAME} <project>`);
|
|
46
|
-
writer
|
|
47
|
+
writeCommands(writer, p.commandFile, (command) => markdownCommand(ctx, { command }));
|
|
47
48
|
writer.writeText(p.plugin, pluginSource(ctx, p.plugin));
|
|
48
49
|
return report;
|
|
49
50
|
},
|
|
50
51
|
uninstall(ctx, writer) {
|
|
51
52
|
const p = paths(ctx);
|
|
52
53
|
editJson(writer, p.config, (value) => (value.mcp?.[SERVER_NAME] ? (delete value.mcp[SERVER_NAME], true) : false));
|
|
53
|
-
writer
|
|
54
|
+
removeCommands(writer, p.commandFile);
|
|
54
55
|
writer.remove(p.plugin);
|
|
55
56
|
},
|
|
56
57
|
status(ctx) {
|
|
57
58
|
const p = paths(ctx);
|
|
58
59
|
return {
|
|
59
60
|
connect: readJsonSafe(p.config, {}).mcp?.[SERVER_NAME] ? 'yes' : 'no',
|
|
60
|
-
command:
|
|
61
|
+
command: commandsStatus(p.commandFile),
|
|
61
62
|
hooks: existsFile(p.plugin) === 'yes' ? 'blocking (plugin)' : 'not installed',
|
|
62
63
|
};
|
|
63
64
|
},
|