dsh-bash-terminal-ts 0.8.7 → 0.9.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.de.md +152 -0
- package/CHANGELOG.es.md +152 -0
- package/CHANGELOG.fr.md +152 -0
- package/CHANGELOG.it.md +152 -0
- package/CHANGELOG.md +201 -0
- package/CHANGELOG.ru.md +152 -0
- package/README.de.md +1 -1
- package/README.en.md +3 -2
- package/README.es.md +1 -1
- package/README.it.md +1 -1
- package/README.md +4 -3
- package/agent-presets/README.md +171 -170
- package/agent-presets/install-presets.mjs +180 -179
- package/agent-presets/standard-win-niu/agent.cordis.yml +271 -0
- package/agent-presets/standard-win-niu/preset.yml +2 -0
- package/cordis.patch.yml +84 -83
- package/dist/client.core.js +10 -1
- package/dist/client.js +10 -1
- package/docs/dsh-plugin-development.md +169 -0
- package/docs/niu-backend.md +197 -0
- package/dsh.plugin.json +22 -22
- package/lib/client.js +10 -1
- package/lib/dsh-types.d.ts +14 -2
- package/lib/index.d.ts +15 -2
- package/lib/index.js +43 -5
- package/lib/locales.js +9 -0
- package/lib/shell-id.d.ts +1 -1
- package/lib/shells.d.ts +1 -0
- package/lib/shells.js +8 -2
- package/lib/terminal.js +4 -0
- package/lib/webterminals/host.js +2 -2
- package/lib/webterminals/mount.js +1 -0
- package/locale/de.json +6 -4
- package/locale/en.json +6 -4
- package/locale/es.json +6 -4
- package/locale/fr.json +6 -4
- package/locale/it.json +6 -4
- package/locale/ja.json +6 -4
- package/locale/ko.json +6 -4
- package/locale/ru.json +6 -4
- package/locale/zh.json +6 -4
- package/package.json +25 -11
- package/scripts/check-artifacts.mjs +96 -93
- package/src/client.tsx +685 -685
- package/src/dsh-types.ts +332 -320
- package/src/index.ts +1316 -1275
- package/src/locales.ts +461 -452
- package/src/shell-id.ts +11 -11
- package/src/shells.ts +279 -272
- package/src/terminal.ts +616 -612
- package/src/webterminals/host.ts +361 -361
- package/src/webterminals/mount.ts +237 -236
package/lib/index.js
CHANGED
|
@@ -34,7 +34,7 @@ const ENTRY_ID = "tool-bash-terminal";
|
|
|
34
34
|
/** Services required before the tool can register. */
|
|
35
35
|
export const inject = ["tools", "systemPrompt", "shellEnv", "subprocess", "settings", "sandbox", "sandboxPolicy"];
|
|
36
36
|
/** The terminal backends this tool exposes, in catalog order. */
|
|
37
|
-
export const SHELLS = ["powershell", "gitbash", "msys2", "wsl", "payload"];
|
|
37
|
+
export const SHELLS = ["powershell", "gitbash", "msys2", "wsl", "payload", "niu"];
|
|
38
38
|
/** The backend used when the caller does not name one. */
|
|
39
39
|
export const DEFAULT_SHELL = "powershell";
|
|
40
40
|
/** Default per-command timeout (ms). */
|
|
@@ -78,7 +78,9 @@ export const Config = z.object({
|
|
|
78
78
|
// Payload gate state is read once per process (paths resolve at startup), so
|
|
79
79
|
// these are deliberately NOT volatile: a flip needs the restart it implies.
|
|
80
80
|
enablePosixPayload: z.boolean().default(false),
|
|
81
|
-
payloadPosixPath: z.string().default("")
|
|
81
|
+
payloadPosixPath: z.string().default(""),
|
|
82
|
+
niuPath: z.string().default(""),
|
|
83
|
+
shellNiu: z.boolean().default(true).volatile()
|
|
82
84
|
});
|
|
83
85
|
// ---- executable resolution ------------------------------------------------
|
|
84
86
|
function candidateExists(candidate) {
|
|
@@ -167,6 +169,31 @@ export function candidateMsys2Paths(env = process.env) {
|
|
|
167
169
|
candidates.push("C:\\msys64\\msys2.exe"); // last resort: see the note above
|
|
168
170
|
return candidates;
|
|
169
171
|
}
|
|
172
|
+
/**
|
|
173
|
+
* Niubash locations, in preference order: the per-user installer default
|
|
174
|
+
* (LOCALAPPDATA\Programs\Niubash) first, then the winget shim link, then a
|
|
175
|
+
* machine-wide install, then PATH entries. Read from the registry on this
|
|
176
|
+
* machine: the installer writes a USER Path entry pointing at the capitalized
|
|
177
|
+
* directory, so the first candidate must match that exact casing on
|
|
178
|
+
* case-sensitive filesystems (Windows itself is case-insensitive).
|
|
179
|
+
*/
|
|
180
|
+
export function candidateNiuPaths(env = process.env) {
|
|
181
|
+
const localAppData = env.LOCALAPPDATA ?? "";
|
|
182
|
+
const programFiles = env.ProgramFiles ?? "C:\\Program Files";
|
|
183
|
+
const candidates = [];
|
|
184
|
+
if (localAppData.length > 0) {
|
|
185
|
+
candidates.push(join(localAppData, "Programs", "Niubash", "niu.exe"));
|
|
186
|
+
candidates.push(join(localAppData, "Microsoft", "WinGet", "Links", "niu.exe"));
|
|
187
|
+
}
|
|
188
|
+
candidates.push(join(programFiles, "Niubash", "niu.exe"));
|
|
189
|
+
for (const entry of (env.PATH ?? "").split(";")) {
|
|
190
|
+
const trimmed = entry.trim().replace(/^"|"$/g, "");
|
|
191
|
+
if (trimmed.length === 0)
|
|
192
|
+
continue;
|
|
193
|
+
candidates.push(join(trimmed, "niu.exe"));
|
|
194
|
+
}
|
|
195
|
+
return candidates;
|
|
196
|
+
}
|
|
170
197
|
export function defaultWslPath(env = process.env) {
|
|
171
198
|
const systemRoot = env.SystemRoot ?? "C:\\Windows";
|
|
172
199
|
return join(systemRoot, "System32", "wsl.exe");
|
|
@@ -184,10 +211,13 @@ export function resolveAllPaths(config = {}, env = process.env, payloadBash) {
|
|
|
184
211
|
const wsl = config.wslPath && config.wslPath.trim().length > 0
|
|
185
212
|
? config.wslPath
|
|
186
213
|
: defaultWslPath(env);
|
|
214
|
+
const niu = config.niuPath && config.niuPath.trim().length > 0
|
|
215
|
+
? config.niuPath
|
|
216
|
+
: resolveFromCandidates(candidateNiuPaths(env));
|
|
187
217
|
// The payload is its OWN backend (first-class catalog row) - it never
|
|
188
218
|
// silently substitutes for the gitbash slot, so a row labelled "Git Bash"
|
|
189
219
|
// always names a shell the machine actually has.
|
|
190
|
-
return { pwsh, gitbash, msys2, wsl, ...(payloadBash !== undefined ? { payload: payloadBash } : {}) };
|
|
220
|
+
return { pwsh, gitbash, msys2, wsl, niu, ...(payloadBash !== undefined ? { payload: payloadBash } : {}) };
|
|
191
221
|
}
|
|
192
222
|
// ---- argv / env construction ------------------------------------------------
|
|
193
223
|
export function buildArgv(shell, command, paths, distro) {
|
|
@@ -205,6 +235,11 @@ export function buildArgv(shell, command, paths, distro) {
|
|
|
205
235
|
// Same login-shell rule as msys2/gitbash: the payload is a
|
|
206
236
|
// Git-for-Windows tree and `-lc` is what gives it a usable PATH.
|
|
207
237
|
return [paths.payload, "-lc", command];
|
|
238
|
+
case "niu":
|
|
239
|
+
// Same login-shell rule: -lc sources the profile chain so winuxcmd's
|
|
240
|
+
// bin directory joins PATH. (niu has no MSYS runtime; see findings F2
|
|
241
|
+
// for the sandbox question this backend answers.)
|
|
242
|
+
return [paths.niu, "-lc", command];
|
|
208
243
|
case "wsl": {
|
|
209
244
|
const distroArg = distro !== undefined && distro.trim().length > 0 ? ["-d", distro.trim()] : [];
|
|
210
245
|
return [paths.wsl, ...distroArg, "-e", "bash", "-lc", command];
|
|
@@ -423,7 +458,8 @@ export const SHELL_DESCRIPTIONS = {
|
|
|
423
458
|
gitbash: "Execute a bash command (Git for Windows bash -lc <command>) and return its stdout/stderr. POSIX syntax; paths like /d/WorkSpace; PATH includes /usr/bin and /mingw64/bin so git, npm, ssh etc. work; environment variables via $NAME.",
|
|
424
459
|
msys2: "Execute a bash command (MSYS2 bash -lc <command>) and return its stdout/stderr. POSIX syntax; paths like /c/...; PATH includes /usr/bin and /mingw64/bin so git, npm, gcc, make etc. work; environment variables via $NAME. MSYS2 provides a full GCC/mingw64 toolchain.",
|
|
425
460
|
wsl: "Execute a Linux bash command (wsl [-d <distro>] -e bash -lc <command>) and return its stdout/stderr. Linux syntax; Windows files under /mnt/d/...; environment variables via $NAME.",
|
|
426
|
-
payload: "Execute a bash command in the plugin's pinned POSIX runtime payload (a digest-verified Git-for-Windows bash -lc <command>) and return its stdout/stderr. POSIX syntax; paths like /c/...; PATH includes /usr/bin so git, npm, ssh etc. work; environment variables via $NAME. Use it only when the user has deliberately enabled the payload backend."
|
|
461
|
+
payload: "Execute a bash command in the plugin's pinned POSIX runtime payload (a digest-verified Git-for-Windows bash -lc <command>) and return its stdout/stderr. POSIX syntax; paths like /c/...; PATH includes /usr/bin so git, npm, ssh etc. work; environment variables via $NAME. Use it only when the user has deliberately enabled the payload backend.",
|
|
462
|
+
niu: "Execute a bash command (Niubash niu -lc <command>) and return its stdout/stderr. GNU bash 5.3 semantics; WinuxCmd applets (ls, cp, rm, grep, find, cat, sed, awk, ...) are on PATH; native Windows paths such as C:\\... are kept as-is while /c/... style arguments are translated; environment variables via $NAME. Niubash is a native binary with no MSYS emulation layer, so /dev/* redirects other than /dev/null do not exist; its startup file is ~/.niubashrc."
|
|
427
463
|
};
|
|
428
464
|
/**
|
|
429
465
|
* Render the model-facing tool description for one backend. The backend is
|
|
@@ -438,7 +474,7 @@ export function toolDescription(backgroundEnabled, shell = DEFAULT_SHELL) {
|
|
|
438
474
|
const base = [
|
|
439
475
|
`The user's chosen default terminal (Settings -> General -> Default terminal) is ${active}; commands run there.`,
|
|
440
476
|
lead,
|
|
441
|
-
"Each call spawns a fresh shell: no state (cwd, variables, aliases) persists between calls - pass workdir instead of using cd. Non-zero exits are reported as [exit code: N] markers; investigate failures before moving on. Long output is truncated to its tail; the full output is saved to a file whose path is reported when available. Commands run under the DSH sandbox: confined modes (read-only / workspace-write) are enforced through ctx.sandbox and deny fail-closed for PowerShell; danger-full-access, Git Bash, MSYS2, the pinned POSIX payload, and WSL run unconfined."
|
|
477
|
+
"Each call spawns a fresh shell: no state (cwd, variables, aliases) persists between calls - pass workdir instead of using cd. Non-zero exits are reported as [exit code: N] markers; investigate failures before moving on. Long output is truncated to its tail; the full output is saved to a file whose path is reported when available. Commands run under the DSH sandbox: confined modes (read-only / workspace-write) are enforced through ctx.sandbox and deny fail-closed for PowerShell; danger-full-access, Git Bash, MSYS2, the pinned POSIX payload, Niubash, and WSL run unconfined."
|
|
442
478
|
].join(" ");
|
|
443
479
|
if (!backgroundEnabled)
|
|
444
480
|
return base;
|
|
@@ -616,6 +652,8 @@ export function apply(ctx, config = {}) {
|
|
|
616
652
|
return read(config.shellWsl, true);
|
|
617
653
|
if (shell === "payload")
|
|
618
654
|
return read(config.shellPayload, false);
|
|
655
|
+
if (shell === "niu")
|
|
656
|
+
return read(config.shellNiu, true);
|
|
619
657
|
return false;
|
|
620
658
|
};
|
|
621
659
|
/**
|
package/lib/locales.js
CHANGED
|
@@ -25,6 +25,7 @@ const zh = {
|
|
|
25
25
|
"dock.state.notInstalled": "未探测到",
|
|
26
26
|
"dock.state.wslPreferred": "已检测到 WSL 发行版(优先用 WSL bash)",
|
|
27
27
|
"shell.payload": "POSIX payload",
|
|
28
|
+
"shell.niu": "Niubash",
|
|
28
29
|
"dock.state.noDistro": "无已安装发行版",
|
|
29
30
|
"dock.state.launcherOnly": "只找到启动器,无法内嵌",
|
|
30
31
|
"dock.powershell.locked": "PowerShell 是保底后端,无法关闭。",
|
|
@@ -72,6 +73,7 @@ const en = {
|
|
|
72
73
|
"dock.state.notInstalled": "Not found",
|
|
73
74
|
"dock.state.wslPreferred": "WSL distro detected (WSL bash preferred)",
|
|
74
75
|
"shell.payload": "POSIX payload",
|
|
76
|
+
"shell.niu": "Niubash",
|
|
75
77
|
"dock.state.noDistro": "No distro installed",
|
|
76
78
|
"dock.state.launcherOnly": "Only a launcher was found; it cannot be embedded",
|
|
77
79
|
"dock.powershell.locked": "PowerShell is the fallback backend and cannot be turned off.",
|
|
@@ -119,6 +121,7 @@ const ja = {
|
|
|
119
121
|
"dock.state.notInstalled": "見つかりません",
|
|
120
122
|
"dock.state.wslPreferred": "WSL ディストリ検出済み(WSL bash 優先)",
|
|
121
123
|
"shell.payload": "POSIX payload",
|
|
124
|
+
"shell.niu": "Niubash",
|
|
122
125
|
"dock.state.noDistro": "インストール済みディストリビューションなし",
|
|
123
126
|
"dock.state.launcherOnly": "ランチャーのみ検出、埋め込み不可",
|
|
124
127
|
"dock.powershell.locked": "PowerShell は最後の代替のため無効化できません。",
|
|
@@ -166,6 +169,7 @@ const ko = {
|
|
|
166
169
|
"dock.state.notInstalled": "탐지되지 않음",
|
|
167
170
|
"dock.state.wslPreferred": "WSL 배포판 감지됨 (WSL bash 우선)",
|
|
168
171
|
"shell.payload": "POSIX payload",
|
|
172
|
+
"shell.niu": "Niubash",
|
|
169
173
|
"dock.state.noDistro": "설치된 배포판 없음",
|
|
170
174
|
"dock.state.launcherOnly": "런처만 발견되어 내장할 수 없음",
|
|
171
175
|
"dock.powershell.locked": "PowerShell은 최종 대체 항목이므로 끌 수 없습니다.",
|
|
@@ -213,6 +217,7 @@ const fr = {
|
|
|
213
217
|
"dock.state.notInstalled": "Non détecté",
|
|
214
218
|
"dock.state.wslPreferred": "Distro WSL détectée (bash WSL préféré)",
|
|
215
219
|
"shell.payload": "POSIX payload",
|
|
220
|
+
"shell.niu": "Niubash",
|
|
216
221
|
"dock.state.noDistro": "Aucune distribution installée",
|
|
217
222
|
"dock.state.launcherOnly": "Seuls des lanceurs ont été trouvés; intégration impossible",
|
|
218
223
|
"dock.powershell.locked": "PowerShell sert de repli final et ne peut pas être désactivé.",
|
|
@@ -260,6 +265,7 @@ const de = {
|
|
|
260
265
|
"dock.state.notInstalled": "Nicht gefunden",
|
|
261
266
|
"dock.state.wslPreferred": "WSL-Distro erkannt (WSL bash bevorzugt)",
|
|
262
267
|
"shell.payload": "POSIX payload",
|
|
268
|
+
"shell.niu": "Niubash",
|
|
263
269
|
"dock.state.noDistro": "Keine Distribution installiert",
|
|
264
270
|
"dock.state.launcherOnly": "Nur Launcher gefunden; Einbettung nicht möglich",
|
|
265
271
|
"dock.powershell.locked": "PowerShell ist die letzte Rückfallmöglichkeit und kann nicht deaktiviert werden.",
|
|
@@ -307,6 +313,7 @@ const it = {
|
|
|
307
313
|
"dock.state.notInstalled": "Non trovato",
|
|
308
314
|
"dock.state.wslPreferred": "Distro WSL rilevata (bash WSL preferito)",
|
|
309
315
|
"shell.payload": "POSIX payload",
|
|
316
|
+
"shell.niu": "Niubash",
|
|
310
317
|
"dock.state.noDistro": "Nessuna distribuzione installata",
|
|
311
318
|
"dock.state.launcherOnly": "Trovato solo un launcher; incorporamento non possibile",
|
|
312
319
|
"dock.powershell.locked": "PowerShell è il ripiego finale e non può essere disattivato.",
|
|
@@ -354,6 +361,7 @@ const ru = {
|
|
|
354
361
|
"dock.state.notInstalled": "Не найден",
|
|
355
362
|
"dock.state.wslPreferred": "Обнаружен дистрибутив WSL (предпочтительнее WSL bash)",
|
|
356
363
|
"shell.payload": "POSIX payload",
|
|
364
|
+
"shell.niu": "Niubash",
|
|
357
365
|
"dock.state.noDistro": "Нет установленных дистрибутивов",
|
|
358
366
|
"dock.state.launcherOnly": "Найден только лаунчер, встраивание невозможно",
|
|
359
367
|
"dock.powershell.locked": "PowerShell — резервный вариант, его нельзя отключить.",
|
|
@@ -401,6 +409,7 @@ const es = {
|
|
|
401
409
|
"dock.state.notInstalled": "No detectado",
|
|
402
410
|
"dock.state.wslPreferred": "Distro de WSL detectada (se prefiere bash de WSL)",
|
|
403
411
|
"shell.payload": "POSIX payload",
|
|
412
|
+
"shell.niu": "Niubash",
|
|
404
413
|
"dock.state.noDistro": "Sin distribución instalada",
|
|
405
414
|
"dock.state.launcherOnly": "Solo se encontró un lanzador; no se puede incrustar",
|
|
406
415
|
"dock.powershell.locked": "PowerShell es el respaldo final y no puede desactivarse.",
|
package/lib/shell-id.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** The five backends, in catalog order (`payload` = the pinned POSIX runtime). */
|
|
2
|
-
export type ShellId = "powershell" | "gitbash" | "msys2" | "wsl" | "payload";
|
|
2
|
+
export type ShellId = "powershell" | "gitbash" | "msys2" | "wsl" | "payload" | "niu";
|
package/lib/shells.d.ts
CHANGED
package/lib/shells.js
CHANGED
|
@@ -18,13 +18,14 @@
|
|
|
18
18
|
/** Catalog order = fallback order: powershell is BOTH first choice and floor. The
|
|
19
19
|
* pinned POSIX payload sits last: it only earns a seat when the machine's own
|
|
20
20
|
* shells are absent, and a detected WSL distro vetoes it before that. */
|
|
21
|
-
export const SHELL_PRIORITY = ["powershell", "gitbash", "msys2", "wsl", "payload"];
|
|
21
|
+
export const SHELL_PRIORITY = ["powershell", "gitbash", "msys2", "wsl", "niu", "payload"];
|
|
22
22
|
/** Display labels. The catalog id/label pair is DECIDED BY THIS TABLE. */
|
|
23
23
|
const LABELS = {
|
|
24
24
|
powershell: "PowerShell",
|
|
25
25
|
gitbash: "Git Bash",
|
|
26
26
|
msys2: "MSYS2",
|
|
27
27
|
wsl: "WSL bash",
|
|
28
|
+
niu: "Niubash",
|
|
28
29
|
payload: "POSIX payload",
|
|
29
30
|
};
|
|
30
31
|
/**
|
|
@@ -70,6 +71,10 @@ export function uiArgv(shell, paths, wslDistro = "") {
|
|
|
70
71
|
// The payload is a Git-for-Windows tree: the interactive rules are the
|
|
71
72
|
// gitbash ones (an interactive non-login shell; its /etc still works).
|
|
72
73
|
return [requirePath(paths.payload, shell), "-i"];
|
|
74
|
+
case "niu":
|
|
75
|
+
// Interactive non-login: niu reads ~/.niubashrc (its only Windows
|
|
76
|
+
// startup file), so the user's prompt and colours survive.
|
|
77
|
+
return [requirePath(paths.niu, shell), "-i"];
|
|
73
78
|
case "wsl": {
|
|
74
79
|
const distro = wslDistro.trim();
|
|
75
80
|
return distro.length > 0
|
|
@@ -110,7 +115,8 @@ function probe(id, facts) {
|
|
|
110
115
|
: id === "gitbash" ? facts.paths.gitbash
|
|
111
116
|
: id === "msys2" ? facts.paths.msys2
|
|
112
117
|
: id === "payload" ? facts.paths.payload
|
|
113
|
-
: facts.paths.
|
|
118
|
+
: id === "niu" ? facts.paths.niu
|
|
119
|
+
: facts.paths.wsl;
|
|
114
120
|
if (path === undefined || path.length === 0) {
|
|
115
121
|
if (id === "payload" && facts.payloadSuppressed === true)
|
|
116
122
|
return { available: false, reason: "wsl-preferred" };
|
package/lib/terminal.js
CHANGED
|
@@ -50,6 +50,10 @@ export function terminalArgv(shell, paths, distro) {
|
|
|
50
50
|
case "powershell": return [paths.pwsh, "-NoLogo", "-NoProfile"];
|
|
51
51
|
case "gitbash": return [paths.gitbash, "-i"];
|
|
52
52
|
case "payload": return [paths.payload, "-i"];
|
|
53
|
+
case "niu":
|
|
54
|
+
// Interactive non-login: reads ~/.niubashrc (the only startup file niu
|
|
55
|
+
// reads on Windows), keeps the user's prompt and colours.
|
|
56
|
+
return [paths.niu, "-i"];
|
|
53
57
|
case "msys2":
|
|
54
58
|
// -l, NOT -lc: this argv carries no command (the PTY itself is the
|
|
55
59
|
// session), and `bash -lc` with no operand dies immediately with
|
package/lib/webterminals/host.js
CHANGED
|
@@ -51,7 +51,7 @@ function num(value, fallback, max) {
|
|
|
51
51
|
* persist nothing, and look fine in the settings page. Two spellings of one fact
|
|
52
52
|
* always drift, so this table is the single place the name appears.
|
|
53
53
|
*/
|
|
54
|
-
const SWITCH_FIELD = { gitbash: "shellGitBash", msys2: "shellMsys2", wsl: "shellWsl", payload: "shellPayload" };
|
|
54
|
+
const SWITCH_FIELD = { gitbash: "shellGitBash", msys2: "shellMsys2", wsl: "shellWsl", payload: "shellPayload", niu: "shellNiu" };
|
|
55
55
|
/**
|
|
56
56
|
* Register the terminal routes.
|
|
57
57
|
* @param webServer - the host webserver (may lack upgrade support).
|
|
@@ -159,7 +159,7 @@ async function dispatch(body, deps) {
|
|
|
159
159
|
const next = requested;
|
|
160
160
|
// Persist first, then answer with a rebuilt catalog: a switch that cannot be
|
|
161
161
|
// stored must not look applied in the settings row.
|
|
162
|
-
for (const key of ["gitbash", "msys2", "wsl", "payload"]) {
|
|
162
|
+
for (const key of ["gitbash", "msys2", "wsl", "payload", "niu"]) {
|
|
163
163
|
if (typeof next[key] === "boolean")
|
|
164
164
|
await deps.writeConfig([SWITCH_FIELD[key]], next[key]);
|
|
165
165
|
}
|
|
@@ -65,6 +65,7 @@ export function mountBrowserTerminals(input) {
|
|
|
65
65
|
// Opt-in twice over: enablePosixPayload provisions the runtime, this
|
|
66
66
|
// switch decides whether a provisioned payload may show in pickers.
|
|
67
67
|
payload: readField("shellPayload", false),
|
|
68
|
+
niu: readField("shellNiu", true),
|
|
68
69
|
});
|
|
69
70
|
const wslDistro = () => readField("wslDistro", "").trim();
|
|
70
71
|
/** The master switch: off hides the child switches and refuses allocations. */
|
package/locale/de.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Unteres Terminal",
|
|
4
|
+
"description": "Shell-Werkzeug plus eingebettetes Terminal im unteren Dock (PowerShell / Git Bash / MSYS2 / WSL / Niubash), mit Aktivierung pro Shell und Rückfallkette."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/en.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Bottom terminal",
|
|
4
|
+
"description": "The shell tool plus an embedded terminal for the bottom dock (PowerShell / Git Bash / MSYS2 / WSL / Niubash), with per-shell activation switches and a default-shell fallback chain."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/es.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Terminal inferior",
|
|
4
|
+
"description": "La herramienta shell y un terminal incrustado del panel inferior (PowerShell / Git Bash / MSYS2 / WSL / Niubash), con activación por shell y cadena de sustitución."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/fr.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Terminal inférieur",
|
|
4
|
+
"description": "L'outil shell et un terminal intégré du dock bas (PowerShell / Git Bash / MSYS2 / WSL / Niubash), avec activation par shell et chaîne de repli."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/it.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Terminale inferiore",
|
|
4
|
+
"description": "Strumento shell e terminale incorporato del dock inferiore (PowerShell / Git Bash / MSYS2 / WSL / Niubash), con attivazione per shell e catena di ripiego."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/ja.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "下部ターミナル",
|
|
4
|
+
"description": "shell ツールと下部ドックの埋め込みターミナル(PowerShell / Git Bash / MSYS2 / WSL / Niubash)。shell 単位の有効化スイッチと既定 shell の代替チェーン付き。"
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/ko.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "하단 터미널",
|
|
4
|
+
"description": "shell 도구와 하단 독의 내장 터미널(PowerShell / Git Bash / MSYS2 / WSL / Niubash). shell별 활성화 스위치와 기본 shell 대체 체인을 제공합니다."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/ru.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "Нижний терминал",
|
|
4
|
+
"description": "Инструмент shell и встроенный терминал нижней панели (PowerShell / Git Bash / MSYS2 / WSL / Niubash) с активацией по оболочкам и цепочкой замещения."
|
|
5
|
+
}
|
|
6
|
+
}
|
package/locale/zh.json
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
{
|
|
2
|
+
"meta": {
|
|
3
|
+
"title": "底部终端",
|
|
4
|
+
"description": "shell 工具与底部工作台终端(PowerShell / Git Bash / MSYS2 / WSL / Niubash),带激活开关与默认 shell 回落链。"
|
|
5
|
+
}
|
|
6
|
+
}
|
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-bash-terminal-ts",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"publishConfig": {
|
|
5
|
+
"registry": "https://registry.npmjs.org",
|
|
5
6
|
"tag": "latest"
|
|
6
7
|
},
|
|
7
|
-
"description": "DSH plugin: one shell tool that runs commands through PowerShell, Git Bash, MSYS2, or
|
|
8
|
+
"description": "DSH plugin: one shell tool that runs commands through PowerShell, Git Bash, MSYS2, WSL or Niubash on Windows, plus an embedded terminal for the bottom dock (dsh-better-sidebar's terminal tab) with per-shell activation switches and a default-shell fallback chain.",
|
|
8
9
|
"author": "drscrewdriver",
|
|
9
10
|
"license": "MIT",
|
|
10
11
|
"repository": {
|
|
@@ -31,7 +32,7 @@
|
|
|
31
32
|
],
|
|
32
33
|
"engines": {
|
|
33
34
|
"node": ">=22",
|
|
34
|
-
"dsh": ">=0.1.
|
|
35
|
+
"dsh": ">=0.1.0-rc.2 <0.3.0-0"
|
|
35
36
|
},
|
|
36
37
|
"type": "module",
|
|
37
38
|
"main": "lib/index.js",
|
|
@@ -48,12 +49,25 @@
|
|
|
48
49
|
"scripts",
|
|
49
50
|
"template",
|
|
50
51
|
"agent-presets",
|
|
52
|
+
"docs",
|
|
51
53
|
"locale",
|
|
52
54
|
"tsconfig.json",
|
|
53
55
|
"tsconfig.client.json",
|
|
54
56
|
"tsconfig.test.json",
|
|
55
57
|
"README.md",
|
|
58
|
+
"README.en.md",
|
|
59
|
+
"README.de.md",
|
|
60
|
+
"README.fr.md",
|
|
61
|
+
"README.it.md",
|
|
62
|
+
"README.ru.md",
|
|
63
|
+
"README.es.md",
|
|
64
|
+
"CHANGELOG.de.md",
|
|
65
|
+
"CHANGELOG.fr.md",
|
|
66
|
+
"CHANGELOG.it.md",
|
|
67
|
+
"CHANGELOG.ru.md",
|
|
68
|
+
"CHANGELOG.es.md",
|
|
56
69
|
"LICENSE",
|
|
70
|
+
"CHANGELOG.md",
|
|
57
71
|
"cordis.patch.yml",
|
|
58
72
|
"dsh.plugin.json",
|
|
59
73
|
"screenshots.json"
|
|
@@ -86,14 +100,14 @@
|
|
|
86
100
|
},
|
|
87
101
|
"peerDependencies": {
|
|
88
102
|
"@deepseek-ai/cordis": "^4.0.2",
|
|
89
|
-
"@deepseek-ai/dsh-client-locale": "0.1.0-rc.2
|
|
90
|
-
"@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.2
|
|
91
|
-
"@deepseek-ai/dsh-llm": "0.1.0-rc.2
|
|
92
|
-
"@deepseek-ai/dsh-sandbox": "0.1.0-rc.2
|
|
93
|
-
"@deepseek-ai/dsh-settings": "0.1.0-rc.2
|
|
94
|
-
"@deepseek-ai/dsh-shell": "0.1.0-rc.2
|
|
95
|
-
"@deepseek-ai/dsh-timeout": "0.1.0-rc.2
|
|
96
|
-
"@deepseek-ai/dsh-tools": "0.1.0-rc.2
|
|
103
|
+
"@deepseek-ai/dsh-client-locale": ">=0.1.0-rc.2 <0.3.0-0",
|
|
104
|
+
"@deepseek-ai/dsh-client-ui-slots": ">=0.1.0-rc.2 <0.3.0-0",
|
|
105
|
+
"@deepseek-ai/dsh-llm": ">=0.1.0-rc.2 <0.3.0-0",
|
|
106
|
+
"@deepseek-ai/dsh-sandbox": ">=0.1.0-rc.2 <0.3.0-0",
|
|
107
|
+
"@deepseek-ai/dsh-settings": ">=0.1.0-rc.2 <0.3.0-0",
|
|
108
|
+
"@deepseek-ai/dsh-shell": ">=0.1.0-rc.2 <0.3.0-0",
|
|
109
|
+
"@deepseek-ai/dsh-timeout": ">=0.1.0-rc.2 <0.3.0-0",
|
|
110
|
+
"@deepseek-ai/dsh-tools": ">=0.1.0-rc.2 <0.3.0-0",
|
|
97
111
|
"react": "^18.2.0"
|
|
98
112
|
},
|
|
99
113
|
"dependencies": {
|