@guillaumemeyer/dsh-plan-approval 0.1.8 → 0.1.10
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/README.md +95 -25
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@ review contract.
|
|
|
9
9
|
|
|
10
10
|
## Features
|
|
11
11
|
|
|
12
|
-
- **Fullscreen review** in the frame-wide `shell.overlay` layer,
|
|
12
|
+
- **Fullscreen review** in the frame-wide `shell.overlay` layer, at **90vw × 90vh**.
|
|
13
13
|
- **Line navigation** (vim-style): `j`/`k` move line-by-line, `gg` jump to top,
|
|
14
14
|
`G` (Shift+g) jump to bottom, with a straight left highlight on the cursor line
|
|
15
15
|
that auto-scrolls.
|
|
@@ -24,30 +24,83 @@ review contract.
|
|
|
24
24
|
- **Actions**: `a` approve · `s` request changes · `y` copy plan · `q` quit plan.
|
|
25
25
|
- A bottom **status line** lists every keyboard shortcut.
|
|
26
26
|
|
|
27
|
-
## Install
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
27
|
+
## Install (into a DSH deployment)
|
|
28
|
+
|
|
29
|
+
This is a `dsh.client` browser plugin, so it must be installed and mounted where DSH
|
|
30
|
+
composes its **web surface** (host/web composition), then the host restarted so the
|
|
31
|
+
client-modules node half produces the bundle.
|
|
32
|
+
|
|
33
|
+
1. **Install the package** into the DSH deployment's web app:
|
|
34
|
+
|
|
35
|
+
```sh
|
|
36
|
+
npm i @guillaumemeyer/dsh-plan-approval
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
2. **Find the web-surface (browser roster) composition.** This is the `cordis.yml` /
|
|
40
|
+
`cordis.patch.yml` in the DSH web app that lists the other browser roster rows
|
|
41
|
+
(`ui-plan`, `ui-user-questions`, `ui-tool`, …). (The shipped `@deepseek-ai/dsh-web-app`
|
|
42
|
+
`cordis.patch.yml` is the reference for this "browser plugin roster" section.)
|
|
43
|
+
|
|
44
|
+
3. **Add one row** to that roster:
|
|
45
|
+
|
|
46
|
+
```yaml
|
|
47
|
+
- id: ui-plan-approval
|
|
48
|
+
name: '@guillaumemeyer/dsh-plan-approval'
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
4. **Restart the DSH host.** The `@deepseek-ai/dsh-client-modules` node half re-scans
|
|
52
|
+
loader entries for packages declaring `dsh.client`, bundles
|
|
53
|
+
`/plugins/@guillaumemeyer/dsh-plan-approval/client.js`, and the browser loads it.
|
|
54
|
+
(With a `pnpm run dev:web` watcher, the bundle is rebuilt automatically without a
|
|
55
|
+
restart; in a production/built deployment a host restart is required.)
|
|
56
|
+
|
|
57
|
+
> The row **must** live in the **web-surface `dsh.client` roster** (a
|
|
58
|
+
> `dsh.client` `platform: "web"` package). Placing it in an agent preset or a
|
|
59
|
+
> non-web composition will **not** be scanned into `window.__DSH_BOOT__`.
|
|
60
|
+
|
|
61
|
+
### Verify it's mounted
|
|
62
|
+
|
|
63
|
+
After restart, the package's browser bundle is served under
|
|
64
|
+
`/plugins/@guillaumemeyer/dsh-plan-approval/client.js`, and the plugin appears in the
|
|
65
|
+
`shell.overlay` slot.
|
|
66
|
+
|
|
67
|
+
## Use it from DSH
|
|
68
|
+
|
|
69
|
+
1. **Enter plan mode** — switch the agent into plan mode (the `/plan` command or the
|
|
70
|
+
session's plan control) and ask it to plan.
|
|
71
|
+
2. **Present a plan** — when the agent has the plan, it calls `exit_plan_mode` with the
|
|
72
|
+
plan markdown. The full-screen review overlay opens automatically.
|
|
73
|
+
3. **Review the plan**:
|
|
74
|
+
- **Navigate**: `j`/`k` move the cursor line, `gg` jump to top, `G` (Shift+g) jump to
|
|
75
|
+
bottom; the plan auto-scrolls to follow the cursor.
|
|
76
|
+
- **Search**: `/` opens the search bar — type to highlight matches, `Enter`/`n` to
|
|
77
|
+
the next match, `N` (Shift+n) to the previous, `Esc` to close.
|
|
78
|
+
- **Comment**: `c` (or **click** any line) anchors an inline comment to that line;
|
|
79
|
+
type it and press `Enter` to add (`Esc` to cancel). Comments show as inline chips.
|
|
80
|
+
- **Copy**: `y` copies the plan, including any inline comments (the merged plan).
|
|
81
|
+
4. **Decide**:
|
|
82
|
+
- `a` **approve** the plan.
|
|
83
|
+
- `s` **request changes** — the feedback box opens; submit your requested changes
|
|
84
|
+
(plus any inline comments) → the agent keeps planning and revises the plan.
|
|
85
|
+
- `q` **quit plan** — cancel the review and go talk instead.
|
|
86
|
+
|
|
87
|
+
The status line at the bottom shows every shortcut: `a approve · s changes · c comment ·
|
|
88
|
+
y copy · q quit · j/k move · gg/G ends · / search`.
|
|
89
|
+
|
|
90
|
+
### Keyboard shortcuts
|
|
91
|
+
|
|
92
|
+
| Key | Action |
|
|
93
|
+
| --- | --- |
|
|
94
|
+
| `a` | Approve the plan |
|
|
95
|
+
| `s` | Request changes (opens feedback box; `Enter` submits) |
|
|
96
|
+
| `c` | Add an inline comment at the current line (`Enter` add, `Esc` cancel) |
|
|
97
|
+
| `y` | Copy the plan (merged with comments) |
|
|
98
|
+
| `q` | Quit / cancel the plan review |
|
|
99
|
+
| `j` / `k` | Move the cursor down / up one line |
|
|
100
|
+
| `gg` | Jump to top |
|
|
101
|
+
| `G` (Shift+g) | Jump to bottom |
|
|
102
|
+
| `/` | Open search (type to highlight; `Enter`/`n` next, `N` prev, `Esc` close) |
|
|
103
|
+
| `Esc` | Close the search/comment box, otherwise quit |
|
|
51
104
|
|
|
52
105
|
## How the review answers map
|
|
53
106
|
|
|
@@ -84,6 +137,23 @@ plus include it in the result `render` so the model sees the comments after appr
|
|
|
84
137
|
This requires a host restart to take effect, and is a change to a shipped package that
|
|
85
138
|
an upgrade would overwrite — ideally upstream it.
|
|
86
139
|
|
|
140
|
+
## Publishing updates
|
|
141
|
+
|
|
142
|
+
To publish a new version, ensure a local `.env` (untracked) holds your npm token, then:
|
|
143
|
+
|
|
144
|
+
```sh
|
|
145
|
+
cp .env.example .env # once: edit to add NPM_TOKEN=...
|
|
146
|
+
npm run release # runs publish:check (preversion), bumps patch, publishes to npm
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
- The token is read from `.env` and referenced by the committed `.npmrc` via `${NPM_TOKEN}`,
|
|
150
|
+
so it is never tracked.
|
|
151
|
+
- `preversion` runs `node --check client.js && npm pack --dry-run` automatically before
|
|
152
|
+
the version bump.
|
|
153
|
+
- The script is named `release` because `publish` is a reserved npm lifecycle name: npm
|
|
154
|
+
auto-runs a `publish` script during `npm publish`. Naming it `publish` made `npm publish`
|
|
155
|
+
re-run the script, bumping and publishing a version on every loop.
|
|
156
|
+
|
|
87
157
|
## Notes
|
|
88
158
|
|
|
89
159
|
- Client-only browser plugin; the node half (`index.js`) is an empty `apply`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@guillaumemeyer/dsh-plan-approval",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.10",
|
|
4
4
|
"description": "Fullscreen, Grok-Build-style DSH plan-review overlay with vim navigation, inline search, inline comments, and comment integration into the plan.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "index.js",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"access": "public"
|
|
33
33
|
},
|
|
34
34
|
"scripts": {
|
|
35
|
-
"
|
|
35
|
+
"release": "node scripts/publish.mjs",
|
|
36
36
|
"publish:dry": "npm pack --dry-run",
|
|
37
37
|
"publish:check": "node --check client.js && npm pack --dry-run",
|
|
38
38
|
"preversion": "npm run publish:check"
|