@xmoon76/dsh-pi-tui 0.5.0 → 0.5.1

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.
@@ -0,0 +1,80 @@
1
+ import { readFileSync, realpathSync } from "node:fs";
2
+ import { dirname, join } from "node:path";
3
+ //#region src/client/launcher/version.ts
4
+ /**
5
+ * The Client-local launcher/version reads: the installed dsh (DeepSeek
6
+ * Harness CLI) version, resolved from the launcher's real path — `process.argv[1]`
7
+ * is the `dsh` bin, whose realpath walks up to the `@deepseek-ai/dsh/package.json`
8
+ * that owns it — plus the bundle's OWN version reads (`bundleVersion`,
9
+ * `packageVersion`). The header and the welcome card show the harness the TUI
10
+ * runs on, not this bundle's own patch level; `dshVersion` is undefined when
11
+ * the launcher path is unreadable. The combined welcome-card display line lives
12
+ * in the application presentation owner (`app/surface/version-display.ts`).
13
+ *
14
+ * This is Client-local platform IO: it reads the local process argv and the
15
+ * locally installed package manifests. The zero-dependency startup island keeps
16
+ * its own private comparator and never imports this module.
17
+ * @module @xmoon76/dsh-pi-tui/client/launcher/version
18
+ */
19
+ /** @returns the installed dsh version string, or undefined. */
20
+ function dshVersion() {
21
+ const bin = process.argv[1];
22
+ if (bin === void 0) return void 0;
23
+ try {
24
+ let dir = dirname(realpathSync(bin));
25
+ for (let depth = 0; depth < 8; depth += 1) {
26
+ try {
27
+ const pkg = JSON.parse(readFileSync(join(dir, "package.json"), "utf8"));
28
+ if (pkg.name === "@deepseek-ai/dsh" && typeof pkg.version === "string") return pkg.version;
29
+ } catch {}
30
+ const parent = dirname(dir);
31
+ if (parent === dir) return void 0;
32
+ dir = parent;
33
+ }
34
+ } catch {}
35
+ }
36
+ /**
37
+ * The bundle's OWN manifest version (`@xmoon76/dsh-pi-tui`), resolved by
38
+ * walking up from THIS module's directory instead of assuming a fixed depth:
39
+ * the source layout (`src/client/launcher/**`, the depth TS8-F2 introduced)
40
+ * and the flat packed layout (`dist/*.mjs`) both reach the shipped manifest,
41
+ * and an installed copy reaches its own `node_modules` manifest first.
42
+ * @returns the version string, or undefined when no own manifest is reachable.
43
+ */
44
+ function ownBundleVersion() {
45
+ let dir = import.meta.dirname;
46
+ for (let depth = 0; depth < 8; depth += 1) {
47
+ try {
48
+ const pkg = JSON.parse(readFileSync(join(dir, "package.json"), "utf8"));
49
+ if (pkg.name === "@xmoon76/dsh-pi-tui" && typeof pkg.version === "string") return pkg.version;
50
+ } catch {}
51
+ const parent = dirname(dir);
52
+ if (parent === dir) return void 0;
53
+ dir = parent;
54
+ }
55
+ }
56
+ /**
57
+ * The bundle's own version, read from package.json at runtime so the welcome
58
+ * card never drifts from the shipped version. The DISPLAYED version prefers
59
+ * the installed dsh version (`dshVersion` — shared with the header badge),
60
+ * falling back to this one.
61
+ * @returns the version string, or a fallback when the file is unreadable.
62
+ */
63
+ function packageVersion() {
64
+ return dshVersion() ?? ownBundleVersion() ?? "0.0.0";
65
+ }
66
+ /**
67
+ * The BUNDLE's OWN version (`@xmoon76/dsh-pi-tui`'s package.json),
68
+ * INDEPENDENT of the installed dsh version. The status snapshot's
69
+ * host.tuiVersion and the footer's `version(format=tui)` item must report
70
+ * the TUI's own patch level — the welcome-card helper above deliberately
71
+ * prefers the dsh version for display, so reusing it made `tui` show the
72
+ * harness version (and `both` show the dsh version twice) inside a real
73
+ * dsh installation (the review's P2).
74
+ * @returns the bundle version string, or a fallback when the file is unreadable.
75
+ */
76
+ function bundleVersion() {
77
+ return ownBundleVersion() ?? "0.0.0";
78
+ }
79
+ //#endregion
80
+ export { dshVersion as n, packageVersion as r, bundleVersion as t };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xmoon76/dsh-pi-tui",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "The dsh-pi-tui bundle: a TUI surface for DeepSeek Harness profiles (dsh --profile pi-tui)",
5
5
  "license": "MIT",
6
6
  "author": "XMoon <xmoonox@gmail.com>",
@@ -84,137 +84,146 @@
84
84
  "peerDependencies": {
85
85
  "@deepseek-ai/cordis": "~4.0.4",
86
86
  "@deepseek-ai/cordis-plugin-loader": "~1.0.5",
87
- "@deepseek-ai/dsh-agent": ">=0.1.7-rc.2",
88
- "@deepseek-ai/dsh-agent-default-model": ">=0.1.7-rc.2",
89
- "@deepseek-ai/dsh-agent-preset-registry": ">=0.1.7-rc.2",
90
- "@deepseek-ai/dsh-api-gateway": ">=0.1.7-rc.2",
91
- "@deepseek-ai/dsh-api-job-controller": ">=0.1.7-rc.2",
92
- "@deepseek-ai/dsh-api-remotes": ">=0.1.7-rc.2",
93
- "@deepseek-ai/dsh-api-session-controller": ">=0.1.7-rc.2",
94
- "@deepseek-ai/dsh-api-settings-controller": ">=0.1.7-rc.2",
95
- "@deepseek-ai/dsh-authorization": ">=0.1.7-rc.2",
96
- "@deepseek-ai/dsh-cmdline": ">=0.1.7-rc.2",
97
- "@deepseek-ai/dsh-commands": ">=0.1.7-rc.2",
98
- "@deepseek-ai/dsh-credentials": ">=0.1.7-rc.2",
99
- "@deepseek-ai/dsh-client-connection": ">=0.1.7-rc.2",
100
- "@deepseek-ai/dsh-client-file-upload": ">=0.1.7-rc.2",
101
- "@deepseek-ai/dsh-goal": ">=0.1.7-rc.2",
102
- "@deepseek-ai/dsh-jobs": ">=0.1.7-rc.2",
103
- "@deepseek-ai/dsh-llm": ">=0.1.7-rc.2",
104
- "@deepseek-ai/dsh-llm-retry": ">=0.1.7-rc.2",
105
- "@deepseek-ai/dsh-permission-presets": ">=0.1.7-rc.2",
106
- "@deepseek-ai/dsh-plan-mode": ">=0.1.7-rc.2",
107
- "@deepseek-ai/dsh-plugin-manager": ">=0.1.7-rc.2",
108
- "@deepseek-ai/dsh-sandbox-policy": ">=0.1.7-rc.2",
109
- "@deepseek-ai/dsh-session": ">=0.1.7-rc.2",
110
- "@deepseek-ai/dsh-session-log-export": ">=0.1.7-rc.2",
111
- "@deepseek-ai/dsh-session-persistence": ">=0.1.7-rc.2",
112
- "@deepseek-ai/dsh-session-stats": ">=0.1.7-rc.2",
113
- "@deepseek-ai/dsh-session-title": ">=0.1.7-rc.2",
114
- "@deepseek-ai/dsh-session-turn-outline": ">=0.1.7-rc.2",
115
- "@deepseek-ai/dsh-settings": ">=0.1.7-rc.2",
116
- "@deepseek-ai/dsh-shell": ">=0.1.7-rc.2",
117
- "@deepseek-ai/dsh-skill": ">=0.1.7-rc.2",
118
- "@deepseek-ai/dsh-subagent": ">=0.1.7-rc.2",
119
- "@deepseek-ai/dsh-token-meter": ">=0.1.7-rc.2",
120
- "@deepseek-ai/dsh-tool-todo": ">=0.1.7-rc.2",
121
- "@deepseek-ai/dsh-tool-workflow": ">=0.1.7-rc.2",
122
- "@deepseek-ai/dsh-tools": ">=0.1.7-rc.2",
123
- "@deepseek-ai/dsh-typert-registry": ">=0.1.7-rc.2",
124
- "@deepseek-ai/dsh-user-approval": ">=0.1.7-rc.2",
125
- "@deepseek-ai/dsh-user-questions": ">=0.1.7-rc.2",
87
+ "@deepseek-ai/dsh-agent": ">=0.2.0-rc.2",
88
+ "@deepseek-ai/dsh-agent-default-model": ">=0.2.0-rc.2",
89
+ "@deepseek-ai/dsh-agent-preset-registry": ">=0.2.0-rc.2",
90
+ "@deepseek-ai/dsh-api-gateway": ">=0.2.0-rc.2",
91
+ "@deepseek-ai/dsh-api-job-controller": ">=0.2.0-rc.2",
92
+ "@deepseek-ai/dsh-api-remotes": ">=0.2.0-rc.2",
93
+ "@deepseek-ai/dsh-api-session-controller": ">=0.2.0-rc.2",
94
+ "@deepseek-ai/dsh-api-settings-controller": ">=0.2.0-rc.2",
95
+ "@deepseek-ai/dsh-authorization": ">=0.2.0-rc.2",
96
+ "@deepseek-ai/dsh-client-connection": ">=0.2.0-rc.2",
97
+ "@deepseek-ai/dsh-client-file-upload": ">=0.2.0-rc.2",
98
+ "@deepseek-ai/dsh-cmdline": ">=0.2.0-rc.2",
99
+ "@deepseek-ai/dsh-commands": ">=0.2.0-rc.2",
100
+ "@deepseek-ai/dsh-credentials": ">=0.2.0-rc.2",
101
+ "@deepseek-ai/dsh-file-reference": ">=0.2.0-rc.2",
102
+ "@deepseek-ai/dsh-goal": ">=0.2.0-rc.2",
103
+ "@deepseek-ai/dsh-jobs": ">=0.2.0-rc.2",
104
+ "@deepseek-ai/dsh-llm": ">=0.2.0-rc.2",
105
+ "@deepseek-ai/dsh-llm-retry": ">=0.2.0-rc.2",
106
+ "@deepseek-ai/dsh-permission-presets": ">=0.2.0-rc.2",
107
+ "@deepseek-ai/dsh-plan-mode": ">=0.2.0-rc.2",
108
+ "@deepseek-ai/dsh-plugin-manager": ">=0.2.0-rc.2",
109
+ "@deepseek-ai/dsh-sandbox-policy": ">=0.2.0-rc.2",
110
+ "@deepseek-ai/dsh-session": ">=0.2.0-rc.2",
111
+ "@deepseek-ai/dsh-session-log-export": ">=0.2.0-rc.2",
112
+ "@deepseek-ai/dsh-session-persistence": ">=0.2.0-rc.2",
113
+ "@deepseek-ai/dsh-session-stats": ">=0.2.0-rc.2",
114
+ "@deepseek-ai/dsh-session-title": ">=0.2.0-rc.2",
115
+ "@deepseek-ai/dsh-session-turn-outline": ">=0.2.0-rc.2",
116
+ "@deepseek-ai/dsh-settings": ">=0.2.0-rc.2",
117
+ "@deepseek-ai/dsh-shell": ">=0.2.0-rc.2",
118
+ "@deepseek-ai/dsh-skill": ">=0.2.0-rc.2",
119
+ "@deepseek-ai/dsh-subagent": ">=0.2.0-rc.2",
120
+ "@deepseek-ai/dsh-token-meter": ">=0.2.0-rc.2",
121
+ "@deepseek-ai/dsh-tool-todo": ">=0.2.0-rc.2",
122
+ "@deepseek-ai/dsh-tool-workflow": ">=0.2.0-rc.2",
123
+ "@deepseek-ai/dsh-tools": ">=0.2.0-rc.2",
124
+ "@deepseek-ai/dsh-typert-protocol": ">=0.2.0-rc.2",
125
+ "@deepseek-ai/dsh-typert-registry": ">=0.2.0-rc.2",
126
+ "@deepseek-ai/dsh-user-approval": ">=0.2.0-rc.2",
127
+ "@deepseek-ai/dsh-user-questions": ">=0.2.0-rc.2",
126
128
  "@deepseek-ai/schemastery": "~3.18.4"
127
129
  },
128
130
  "devDependencies": {
129
131
  "@deepseek-ai/cordis": "~4.0.4",
130
132
  "@deepseek-ai/cordis-plugin-loader": "~1.0.5",
131
- "@deepseek-ai/dsh-agent": "0.2.0-rc.1",
132
- "@deepseek-ai/dsh-agent-default-model": "0.2.0-rc.1",
133
- "@deepseek-ai/dsh-agent-instructions": "0.2.0-rc.1",
134
- "@deepseek-ai/dsh-agent-loop": "0.2.0-rc.1",
135
- "@deepseek-ai/dsh-agent-loop-testkit": "0.2.0-rc.1",
136
- "@deepseek-ai/dsh-agent-preset": "0.2.0-rc.1",
137
- "@deepseek-ai/dsh-agent-preset-registry": "0.2.0-rc.1",
138
- "@deepseek-ai/dsh-agent-tool-presentation": "0.2.0-rc.1",
139
- "@deepseek-ai/dsh-api-gateway": "0.2.0-rc.1",
140
- "@deepseek-ai/dsh-api-job-controller": "0.2.0-rc.1",
141
- "@deepseek-ai/dsh-api-remotes": "0.2.0-rc.1",
142
- "@deepseek-ai/dsh-api-session-controller": "0.2.0-rc.1",
143
- "@deepseek-ai/dsh-api-settings-controller": "0.2.0-rc.1",
144
- "@deepseek-ai/dsh-attachment": "0.2.0-rc.1",
145
- "@deepseek-ai/dsh-authorization": "0.2.0-rc.1",
146
- "@deepseek-ai/dsh-brand": "0.2.0-rc.1",
147
- "@deepseek-ai/dsh-client-connection": "0.2.0-rc.1",
148
- "@deepseek-ai/dsh-client-file-upload": "0.2.0-rc.1",
149
- "@deepseek-ai/dsh-client-store": "0.2.0-rc.1",
150
- "@deepseek-ai/dsh-cmdline": "0.2.0-rc.1",
151
- "@deepseek-ai/dsh-command-compact": "0.2.0-rc.1",
152
- "@deepseek-ai/dsh-command-goal": "0.2.0-rc.1",
153
- "@deepseek-ai/dsh-commands": "0.2.0-rc.1",
154
- "@deepseek-ai/dsh-compaction-basic": "0.2.0-rc.1",
155
- "@deepseek-ai/dsh-compaction-tool-result-pruner": "0.2.0-rc.1",
156
- "@deepseek-ai/dsh-credentials": "0.2.0-rc.1",
157
- "@deepseek-ai/dsh-fs-local": "0.2.0-rc.1",
158
- "@deepseek-ai/dsh-goal": "0.2.0-rc.1",
159
- "@deepseek-ai/dsh-invariants": "0.2.0-rc.1",
160
- "@deepseek-ai/dsh-jobs": "0.2.0-rc.1",
161
- "@deepseek-ai/dsh-jobs-local": "0.2.0-rc.1",
162
- "@deepseek-ai/dsh-llm": "0.2.0-rc.1",
163
- "@deepseek-ai/dsh-llm-retry": "0.2.0-rc.1",
164
- "@deepseek-ai/dsh-permission-presets": "0.2.0-rc.1",
165
- "@deepseek-ai/dsh-persona": "0.2.0-rc.1",
166
- "@deepseek-ai/dsh-plan-mode": "0.2.0-rc.1",
167
- "@deepseek-ai/dsh-plugin-manager": "0.2.0-rc.1",
168
- "@deepseek-ai/dsh-remote-mock": "0.2.0-rc.1",
169
- "@deepseek-ai/dsh-sandbox-policy": "0.2.0-rc.1",
170
- "@deepseek-ai/dsh-scope": "0.2.0-rc.1",
171
- "@deepseek-ai/dsh-session": "0.2.0-rc.1",
172
- "@deepseek-ai/dsh-session-format": "0.2.0-rc.1",
173
- "@deepseek-ai/dsh-session-format-v3-to-v4": "0.2.0-rc.1",
174
- "@deepseek-ai/dsh-session-log-export": "0.2.0-rc.1",
175
- "@deepseek-ai/dsh-session-persistence": "0.2.0-rc.1",
176
- "@deepseek-ai/dsh-session-persistence-jsonl": "0.2.0-rc.1",
177
- "@deepseek-ai/dsh-session-projection": "0.2.0-rc.1",
178
- "@deepseek-ai/dsh-session-query": "0.2.0-rc.1",
179
- "@deepseek-ai/dsh-session-query-sqlite": "0.2.0-rc.1",
180
- "@deepseek-ai/dsh-session-stats": "0.2.0-rc.1",
181
- "@deepseek-ai/dsh-session-title": "0.2.0-rc.1",
182
- "@deepseek-ai/dsh-session-turn-outline": "0.2.0-rc.1",
183
- "@deepseek-ai/dsh-settings": "0.2.0-rc.1",
184
- "@deepseek-ai/dsh-shell": "0.2.0-rc.1",
185
- "@deepseek-ai/dsh-skill": "0.2.0-rc.1",
186
- "@deepseek-ai/dsh-skill-filesystem": "0.2.0-rc.1",
187
- "@deepseek-ai/dsh-storage": "0.2.0-rc.1",
188
- "@deepseek-ai/dsh-storage-domain": "0.2.0-rc.1",
189
- "@deepseek-ai/dsh-storage-json": "0.2.0-rc.1",
190
- "@deepseek-ai/dsh-subagent": "0.2.0-rc.1",
191
- "@deepseek-ai/dsh-subagent-spawn-in-process": "0.2.0-rc.1",
192
- "@deepseek-ai/dsh-system-prompt": "0.2.0-rc.1",
193
- "@deepseek-ai/dsh-terminal": "0.2.0-rc.1",
194
- "@deepseek-ai/dsh-timeout": "0.2.0-rc.1",
195
- "@deepseek-ai/dsh-token-meter": "0.2.0-rc.1",
196
- "@deepseek-ai/dsh-tool-ask-user": "0.2.0-rc.1",
197
- "@deepseek-ai/dsh-tool-cordis": "0.2.0-rc.1",
198
- "@deepseek-ai/dsh-tool-fs": "0.2.0-rc.1",
199
- "@deepseek-ai/dsh-tool-fs-search": "0.2.0-rc.1",
200
- "@deepseek-ai/dsh-tool-goal": "0.2.0-rc.1",
201
- "@deepseek-ai/dsh-tool-jobs": "0.2.0-rc.1",
202
- "@deepseek-ai/dsh-tool-ralph": "0.2.0-rc.1",
203
- "@deepseek-ai/dsh-tool-skill": "0.2.0-rc.1",
204
- "@deepseek-ai/dsh-tool-str-replace-editor": "0.2.0-rc.1",
205
- "@deepseek-ai/dsh-tool-subagent": "0.2.0-rc.1",
206
- "@deepseek-ai/dsh-tool-subagent-control": "0.2.0-rc.1",
207
- "@deepseek-ai/dsh-tool-todo": "0.2.0-rc.1",
208
- "@deepseek-ai/dsh-tool-web": "0.2.0-rc.1",
209
- "@deepseek-ai/dsh-tool-workflow": "0.2.0-rc.1",
210
- "@deepseek-ai/dsh-tools": "0.2.0-rc.1",
211
- "@deepseek-ai/dsh-typert-protocol": "0.2.0-rc.1",
212
- "@deepseek-ai/dsh-typert-registry": "0.2.0-rc.1",
213
- "@deepseek-ai/dsh-user-approval": "0.2.0-rc.1",
214
- "@deepseek-ai/dsh-user-questions": "0.2.0-rc.1",
215
- "@deepseek-ai/dsh-web-app": "0.2.0-rc.1",
216
- "@deepseek-ai/dsh-workspace": "0.2.0-rc.1",
133
+ "@deepseek-ai/dsh-agent": "0.2.0-rc.2",
134
+ "@deepseek-ai/dsh-agent-default-model": "0.2.0-rc.2",
135
+ "@deepseek-ai/dsh-agent-instructions": "0.2.0-rc.2",
136
+ "@deepseek-ai/dsh-agent-loop": "0.2.0-rc.2",
137
+ "@deepseek-ai/dsh-agent-loop-testkit": "0.2.0-rc.2",
138
+ "@deepseek-ai/dsh-agent-preset": "0.2.0-rc.2",
139
+ "@deepseek-ai/dsh-agent-preset-registry": "0.2.0-rc.2",
140
+ "@deepseek-ai/dsh-agent-tool-presentation": "0.2.0-rc.2",
141
+ "@deepseek-ai/dsh-api-gateway": "0.2.0-rc.2",
142
+ "@deepseek-ai/dsh-api-job-controller": "0.2.0-rc.2",
143
+ "@deepseek-ai/dsh-api-remotes": "0.2.0-rc.2",
144
+ "@deepseek-ai/dsh-api-session-controller": "0.2.0-rc.2",
145
+ "@deepseek-ai/dsh-api-settings-controller": "0.2.0-rc.2",
146
+ "@deepseek-ai/dsh-app-boot": "0.2.0-rc.2",
147
+ "@deepseek-ai/dsh-attachment": "0.2.0-rc.2",
148
+ "@deepseek-ai/dsh-attachment-local": "0.2.0-rc.2",
149
+ "@deepseek-ai/dsh-authorization": "0.2.0-rc.2",
150
+ "@deepseek-ai/dsh-brand": "0.2.0-rc.2",
151
+ "@deepseek-ai/dsh-client-connection": "0.2.0-rc.2",
152
+ "@deepseek-ai/dsh-client-file-upload": "0.2.0-rc.2",
153
+ "@deepseek-ai/dsh-client-store": "0.2.0-rc.2",
154
+ "@deepseek-ai/dsh-cmdline": "0.2.0-rc.2",
155
+ "@deepseek-ai/dsh-command-compact": "0.2.0-rc.2",
156
+ "@deepseek-ai/dsh-command-goal": "0.2.0-rc.2",
157
+ "@deepseek-ai/dsh-commands": "0.2.0-rc.2",
158
+ "@deepseek-ai/dsh-compaction-basic": "0.2.0-rc.2",
159
+ "@deepseek-ai/dsh-compaction-tool-result-pruner": "0.2.0-rc.2",
160
+ "@deepseek-ai/dsh-config-editor": "0.2.0-rc.2",
161
+ "@deepseek-ai/dsh-credentials": "0.2.0-rc.2",
162
+ "@deepseek-ai/dsh-credentials-local": "0.2.0-rc.2",
163
+ "@deepseek-ai/dsh-file-reference": "0.2.0-rc.2",
164
+ "@deepseek-ai/dsh-file-reference-local": "0.2.0-rc.2",
165
+ "@deepseek-ai/dsh-fs-local": "0.2.0-rc.2",
166
+ "@deepseek-ai/dsh-goal": "0.2.0-rc.2",
167
+ "@deepseek-ai/dsh-invariants": "0.2.0-rc.2",
168
+ "@deepseek-ai/dsh-jobs": "0.2.0-rc.2",
169
+ "@deepseek-ai/dsh-jobs-local": "0.2.0-rc.2",
170
+ "@deepseek-ai/dsh-llm": "0.2.0-rc.2",
171
+ "@deepseek-ai/dsh-llm-retry": "0.2.0-rc.2",
172
+ "@deepseek-ai/dsh-permission-presets": "0.2.0-rc.2",
173
+ "@deepseek-ai/dsh-persona": "0.2.0-rc.2",
174
+ "@deepseek-ai/dsh-plan-mode": "0.2.0-rc.2",
175
+ "@deepseek-ai/dsh-plugin-manager": "0.2.0-rc.2",
176
+ "@deepseek-ai/dsh-remote-mock": "0.2.0-rc.2",
177
+ "@deepseek-ai/dsh-sandbox-policy": "0.2.0-rc.2",
178
+ "@deepseek-ai/dsh-scope": "0.2.0-rc.2",
179
+ "@deepseek-ai/dsh-session": "0.2.0-rc.2",
180
+ "@deepseek-ai/dsh-session-format": "0.2.0-rc.2",
181
+ "@deepseek-ai/dsh-session-format-v3-to-v4": "0.2.0-rc.2",
182
+ "@deepseek-ai/dsh-session-log-export": "0.2.0-rc.2",
183
+ "@deepseek-ai/dsh-session-persistence": "0.2.0-rc.2",
184
+ "@deepseek-ai/dsh-session-persistence-jsonl": "0.2.0-rc.2",
185
+ "@deepseek-ai/dsh-session-projection": "0.2.0-rc.2",
186
+ "@deepseek-ai/dsh-session-query": "0.2.0-rc.2",
187
+ "@deepseek-ai/dsh-session-query-sqlite": "0.2.0-rc.2",
188
+ "@deepseek-ai/dsh-session-stats": "0.2.0-rc.2",
189
+ "@deepseek-ai/dsh-session-title": "0.2.0-rc.2",
190
+ "@deepseek-ai/dsh-session-turn-outline": "0.2.0-rc.2",
191
+ "@deepseek-ai/dsh-settings": "0.2.0-rc.2",
192
+ "@deepseek-ai/dsh-shell": "0.2.0-rc.2",
193
+ "@deepseek-ai/dsh-skill": "0.2.0-rc.2",
194
+ "@deepseek-ai/dsh-skill-filesystem": "0.2.0-rc.2",
195
+ "@deepseek-ai/dsh-storage": "0.2.0-rc.2",
196
+ "@deepseek-ai/dsh-storage-domain": "0.2.0-rc.2",
197
+ "@deepseek-ai/dsh-storage-json": "0.2.0-rc.2",
198
+ "@deepseek-ai/dsh-subagent": "0.2.0-rc.2",
199
+ "@deepseek-ai/dsh-subagent-spawn-in-process": "0.2.0-rc.2",
200
+ "@deepseek-ai/dsh-system-prompt": "0.2.0-rc.2",
201
+ "@deepseek-ai/dsh-terminal": "0.2.0-rc.2",
202
+ "@deepseek-ai/dsh-timeout": "0.2.0-rc.2",
203
+ "@deepseek-ai/dsh-token-meter": "0.2.0-rc.2",
204
+ "@deepseek-ai/dsh-tool-ask-user": "0.2.0-rc.2",
205
+ "@deepseek-ai/dsh-tool-cordis": "0.2.0-rc.2",
206
+ "@deepseek-ai/dsh-tool-fs": "0.2.0-rc.2",
207
+ "@deepseek-ai/dsh-tool-fs-search": "0.2.0-rc.2",
208
+ "@deepseek-ai/dsh-tool-goal": "0.2.0-rc.2",
209
+ "@deepseek-ai/dsh-tool-jobs": "0.2.0-rc.2",
210
+ "@deepseek-ai/dsh-tool-ralph": "0.2.0-rc.2",
211
+ "@deepseek-ai/dsh-tool-skill": "0.2.0-rc.2",
212
+ "@deepseek-ai/dsh-tool-str-replace-editor": "0.2.0-rc.2",
213
+ "@deepseek-ai/dsh-tool-subagent": "0.2.0-rc.2",
214
+ "@deepseek-ai/dsh-tool-subagent-control": "0.2.0-rc.2",
215
+ "@deepseek-ai/dsh-tool-todo": "0.2.0-rc.2",
216
+ "@deepseek-ai/dsh-tool-web": "0.2.0-rc.2",
217
+ "@deepseek-ai/dsh-tool-workflow": "0.2.0-rc.2",
218
+ "@deepseek-ai/dsh-tools": "0.2.0-rc.2",
219
+ "@deepseek-ai/dsh-typert-protocol": "0.2.0-rc.2",
220
+ "@deepseek-ai/dsh-typert-registry": "0.2.0-rc.2",
221
+ "@deepseek-ai/dsh-user-approval": "0.2.0-rc.2",
222
+ "@deepseek-ai/dsh-user-questions": "0.2.0-rc.2",
223
+ "@deepseek-ai/dsh-web-app": "0.2.0-rc.2",
224
+ "@deepseek-ai/dsh-workspace": "0.2.0-rc.2",
217
225
  "@deepseek-ai/schemastery": "~3.18.4",
226
+ "@stencil-hq/tern": "0.1.0",
218
227
  "@types/node": "^22.0.0",
219
228
  "@xmoon76/pi-tui": "^0.84.4",
220
229
  "@xterm/headless": "5.5.0",
@@ -263,6 +272,7 @@
263
272
  "smoke:remote-d2-closure": "node scripts/dsh-remote-d2-closure-smoke.mjs",
264
273
  "smoke:remote-session-lifecycle-parity": "node scripts/dsh-remote-session-lifecycle-parity-smoke.mjs",
265
274
  "smoke:boundary": "node scripts/dsh-runtime-boundary-smoke.mjs",
275
+ "smoke:pi-tui-file-reference-built": "node --import tsx/esm scripts/pi-tui-file-reference-built-smoke.mjs",
266
276
  "smoke:startup-strictness": "node scripts/startup-strictness-smoke.mjs",
267
277
  "dsh:source:pack": "node scripts/dsh-source-pack.mjs",
268
278
  "compat:dsh:source": "node scripts/dsh-source-verify.mjs",
@@ -289,9 +299,9 @@
289
299
  "verify:prepush": "pnpm typecheck:fork && pnpm typecheck:bench && pnpm test:fork && pnpm test:docs && pnpm test:tooling && pnpm gate:installation-doc && pnpm gate:pi-divergence-ledger && pnpm gate:pi-vendor-diff --strict && node scripts/naming-gate.mjs && node scripts/check-no-session-events.mjs && pnpm gate:boundary && pnpm gate:architecture && pnpm gate:keybindings && pnpm audit --prod --audit-level high && pnpm pack:release",
290
300
  "verify:prepush:nofork": "pnpm typecheck:bench && pnpm test:docs && pnpm test:tooling && pnpm gate:installation-doc && pnpm gate:pi-divergence-ledger && pnpm gate:pi-vendor-diff --strict && node scripts/naming-gate.mjs && node scripts/check-no-session-events.mjs && pnpm gate:boundary && pnpm gate:architecture && pnpm gate:keybindings && pnpm audit --prod --audit-level high && pnpm pack:release",
291
301
  "gate:boundary": "node scripts/client-boundary-gate.mjs",
292
- "gate:architecture": "node scripts/pre-m3-architecture-gate.mjs",
302
+ "gate:architecture": "node scripts/application-architecture-gate.mjs",
293
303
  "gate:keybindings": "node --import tsx/esm scripts/check-host-keybindings.mts",
294
- "test:tooling": "node scripts/run-with-temp-root.mjs node --test test/bench-smoke.test.mjs test/dev-environment.test.mjs test/dev-bootstrap-ephemeral.test.mjs test/client-server-migration.test.mjs test/pre-push-hook.test.mjs test/pre-push-stages.test.mjs test/dsh-ci-context.test.mjs test/dsh-distribution.test.mjs test/dsh-npm-verify.test.mjs test/dsh-peer-window.test.mjs test/dsh-process.test.mjs test/dsh-runtime-boundary.test.mjs test/dsh-p1-profile-smoke.test.mjs test/dsh-source-identity.test.mjs test/dsh-source-leak.test.mjs test/release-context.test.mjs test/release-notes.test.mjs test/source-mode-rules.test.mjs test/client-boundary-gate.test.mjs test/pre-m3-architecture-gate.test.mjs test/tarball-source-install.test.mjs test/pi2dsh-compat-smoke.test.mjs test/temp-hygiene-gate.test.mjs test/pi-vendor-diff-gate.test.mjs test/pi-divergence-ledger-gate.test.mjs test/run-with-temp-root.test.mjs test/raw-persistence-coupling-gate.test.mjs test/dsh-preset-parity.test.mjs test/retired-source-scan.test.mjs test/runtime-hardening-profile.test.mjs",
304
+ "test:tooling": "node scripts/run-with-temp-root.mjs node --test test/bench-smoke.test.mjs test/dev-environment.test.mjs test/dev-bootstrap-ephemeral.test.mjs test/client-server-migration.test.mjs test/pre-push-hook.test.mjs test/pre-push-stages.test.mjs test/dsh-ci-context.test.mjs test/dsh-distribution.test.mjs test/dsh-npm-verify.test.mjs test/dsh-peer-window.test.mjs test/dsh-process.test.mjs test/dsh-runtime-boundary.test.mjs test/dsh-p1-profile-smoke.test.mjs test/dsh-source-identity.test.mjs test/dsh-source-leak.test.mjs test/release-context.test.mjs test/release-notes.test.mjs test/source-mode-rules.test.mjs test/client-boundary-gate.test.mjs test/application-architecture-gate.test.mjs test/host-keybindings-gate.test.mjs test/tarball-source-install.test.mjs test/pi2dsh-compat-smoke.test.mjs test/temp-hygiene-gate.test.mjs test/pi-vendor-diff-gate.test.mjs test/pi-divergence-ledger-gate.test.mjs test/run-with-temp-root.test.mjs test/raw-persistence-coupling-gate.test.mjs test/dsh-preset-parity.test.mjs test/retired-source-scan.test.mjs test/runtime-hardening-profile.test.mjs",
295
305
  "test:product": "node scripts/run-with-temp-root.mjs node --test test/*.test.ts test/tarball-smoke.test.mjs",
296
306
  "gen:dsh-presets": "node scripts/generate-dsh-presets.mjs",
297
307
  "gate:dsh-preset-parity": "node scripts/generate-dsh-presets.mjs --check",
@@ -1,76 +0,0 @@
1
- import { readFileSync, realpathSync } from "node:fs";
2
- import { dirname, join } from "node:path";
3
- //#region src/dsh-version.ts
4
- /**
5
- * The installed dsh (DeepSeek Harness CLI) version, resolved from the
6
- * launcher's real path: `process.argv[1]` is the `dsh` bin, whose realpath
7
- * walks up to the `@deepseek-ai/dsh/package.json` that owns it. The header
8
- * and the welcome card show the harness the TUI runs on, not this bundle's
9
- * own patch level. Undefined when the launcher path is unreadable.
10
- *
11
- * The module also owns the bundle's OWN version reads (`bundleVersion`) and
12
- * the combined welcome-card display line (`versionDisplay`).
13
- * @module @xmoon76/dsh-pi-tui/dsh-version
14
- */
15
- /** @returns the installed dsh version string, or undefined. */
16
- function dshVersion() {
17
- const bin = process.argv[1];
18
- if (bin === void 0) return void 0;
19
- try {
20
- let dir = dirname(realpathSync(bin));
21
- for (let depth = 0; depth < 8; depth += 1) {
22
- try {
23
- const pkg = JSON.parse(readFileSync(join(dir, "package.json"), "utf8"));
24
- if (pkg.name === "@deepseek-ai/dsh" && typeof pkg.version === "string") return pkg.version;
25
- } catch {}
26
- const parent = dirname(dir);
27
- if (parent === dir) return void 0;
28
- dir = parent;
29
- }
30
- } catch {}
31
- }
32
- /**
33
- * The bundle's own version, read from package.json at runtime so the welcome
34
- * card never drifts from the shipped version. The DISPLAYED version prefers
35
- * the installed dsh version (`dshVersion` — shared with the header badge
36
- * via src/dsh-version.ts), falling back to this one.
37
- * @returns the version string, or a fallback when the file is unreadable.
38
- */
39
- function packageVersion() {
40
- try {
41
- const pkg = JSON.parse(readFileSync(join(import.meta.dirname, "..", "package.json"), "utf8"));
42
- return dshVersion() ?? pkg.version ?? "0.0.0";
43
- } catch {
44
- return dshVersion() ?? "0.0.0";
45
- }
46
- }
47
- /**
48
- * The welcome card's version line: the installed dsh version plus the
49
- * bundle's own version (header-badge parity — `dsh-0.1.7-rc.2 ·
50
- * tui-v0.4.9`). Without a resolvable dsh launcher it degrades to
51
- * the bundle version alone.
52
- * @returns the combined version string.
53
- */
54
- function versionDisplay() {
55
- const dsh = dshVersion();
56
- return dsh === void 0 ? `tui-v${bundleVersion()}` : `dsh-${dsh} · tui-v${bundleVersion()}`;
57
- }
58
- /**
59
- * The BUNDLE's OWN version (`@xmoon76/dsh-pi-tui`'s package.json),
60
- * INDEPENDENT of the installed dsh version. The status snapshot's
61
- * host.tuiVersion and the footer's `version(format=tui)` item must report
62
- * the TUI's own patch level — the welcome-card helper above deliberately
63
- * prefers the dsh version for display, so reusing it made `tui` show the
64
- * harness version (and `both` show the dsh version twice) inside a real
65
- * dsh installation (the review's P2).
66
- * @returns the bundle version string, or a fallback when the file is unreadable.
67
- */
68
- function bundleVersion() {
69
- try {
70
- return JSON.parse(readFileSync(join(import.meta.dirname, "..", "package.json"), "utf8")).version ?? "0.0.0";
71
- } catch {
72
- return "0.0.0";
73
- }
74
- }
75
- //#endregion
76
- export { versionDisplay as i, dshVersion as n, packageVersion as r, bundleVersion as t };