@xiaoso/dsh-tool-plus 0.1.2 → 0.1.3
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.en.md
CHANGED
|
@@ -110,7 +110,7 @@ Works out of the box, no configuration needed. Common tweaks: background thresho
|
|
|
110
110
|
- **dsh CLI**: installed globally, `npm i -g @deepseek-ai/dsh`
|
|
111
111
|
- **Node.js** ≥ 22.19 or ≥ 24
|
|
112
112
|
- **Git Bash** (recommended): serves as the bash execution environment on Windows
|
|
113
|
-
- Targets DeepSeek Harness `dsh` v0.1.
|
|
113
|
+
- Targets DeepSeek Harness `dsh` v0.1.2-rc.1 (pre-release; interfaces may change)
|
|
114
114
|
|
|
115
115
|
## Notes
|
|
116
116
|
|
package/README.md
CHANGED
|
@@ -106,7 +106,7 @@ npx @xiaoso/dsh-tool-plus-presets
|
|
|
106
106
|
- **dsh CLI**:需全局安装,`npm i -g @deepseek-ai/dsh`
|
|
107
107
|
- **Node.js** ≥ 22.19 或 ≥ 24
|
|
108
108
|
- **Git Bash**(推荐):Windows 上作为 bash 执行环境
|
|
109
|
-
- 适用于 DeepSeek Harness `dsh` v0.1.
|
|
109
|
+
- 适用于 DeepSeek Harness `dsh` v0.1.2-rc.1(pre-release,接口可能变动)
|
|
110
110
|
|
|
111
111
|
## 注意事项
|
|
112
112
|
|
package/lib/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ __installBunShim();
|
|
|
3
3
|
import { n as fs_promises_shim_exports, t as exists } from "./fs-promises-shim-Bx0fpxuk.mjs";
|
|
4
4
|
import { i as setRuntimeLogger, n as systemChromiumCandidatesForTest, r as runtimeLogger } from "./launch-DwpE70Pv.mjs";
|
|
5
5
|
import { $ as peekFile, A as formatAge, C as error, F as $envpos, I as $flag, M as formatCount, P as $env, Q as isProbablyBinary, S as debug, T as warn, U as getAutoQaDbPath, V as VERSION, X as getRemoteDir, Y as getPuppeteerDir, b as isEnotdir, c as combineSignals, d as $which, j as formatBytes$1, k as installBunShim, l as exec, p as readImageMetadata, q as getInstallId, tt as untilAborted, u as render, v as hasFsCode, y as isEnoent } from "./src-D_e1qMwi.mjs";
|
|
6
|
-
import { C as truncateToWidth$1, S as replaceTabs, _ as formatCodeFrameLine, a as fetchBinary, b as LRUCache, c as getParallelExtractContent, d as convertFileWithMarkit, f as Settings, g as capParseErrors, h as OMP_DEFAULTS, i as convertWithMarkit, l as ensureTool, m as settings, o as extractWithParallel, p as isSettingsInitialized, s as findParallelApiKey, u as CONVERTIBLE_EXTENSIONS, v as formatParseErrors, x as padding, y as shortenPath } from "./utils-
|
|
6
|
+
import { C as truncateToWidth$1, S as replaceTabs, _ as formatCodeFrameLine, a as fetchBinary, b as LRUCache, c as getParallelExtractContent, d as convertFileWithMarkit, f as Settings, g as capParseErrors, h as OMP_DEFAULTS, i as convertWithMarkit, l as ensureTool, m as settings, o as extractWithParallel, p as isSettingsInitialized, s as findParallelApiKey, u as CONVERTIBLE_EXTENSIONS, v as formatParseErrors, x as padding, y as shortenPath } from "./utils-DEUxgLCs.mjs";
|
|
7
7
|
import { t as sanitizeText } from "./sanitize-text-CfcXzw5X.mjs";
|
|
8
8
|
import { n as isRecord$2 } from "./type-guards-B9VVjRDK.mjs";
|
|
9
9
|
import { n as ToolError, r as throwIfAborted, t as ToolAbortError } from "./tool-errors-DoyxivAR.mjs";
|
|
@@ -25,7 +25,6 @@ import { fileURLToPath } from "node:url";
|
|
|
25
25
|
import { scheduler } from "node:timers/promises";
|
|
26
26
|
import { randomBytes } from "node:crypto";
|
|
27
27
|
import z from "@deepseek-ai/schemastery";
|
|
28
|
-
import { installSettingsSection, settingsNamespace } from "@deepseek-ai/dsh-settings";
|
|
29
28
|
import { type } from "@oh-my-pi/omptype";
|
|
30
29
|
import { DatabaseSync } from "node:sqlite";
|
|
31
30
|
//#region src/tools/bash/shell-tokenize.ts
|
|
@@ -2764,6 +2763,7 @@ function startBashJob(options) {
|
|
|
2764
2763
|
timeoutMs: timeoutMs ?? null,
|
|
2765
2764
|
wallTimeMs,
|
|
2766
2765
|
...result.workingDir !== void 0 ? { workingDir: result.workingDir } : {},
|
|
2766
|
+
...result.minimized !== void 0 ? { minimized: result.minimized } : {},
|
|
2767
2767
|
output: {
|
|
2768
2768
|
text,
|
|
2769
2769
|
truncated: result.truncated,
|
|
@@ -3986,7 +3986,7 @@ TOOL_PLUS_FIELDS.map((field) => field.name);
|
|
|
3986
3986
|
//#endregion
|
|
3987
3987
|
//#region src/config/settings.ts
|
|
3988
3988
|
/** Settings namespace of this plugin, served to the web Plugins page. */
|
|
3989
|
-
const BASH_PLUS_SETTINGS_NS =
|
|
3989
|
+
const BASH_PLUS_SETTINGS_NS = "tool-plus";
|
|
3990
3990
|
/** OMP-parity defaults for the completion-message truncation policy. */
|
|
3991
3991
|
const DEFAULT_OUTPUT_TRUNCATE = {
|
|
3992
3992
|
strategy: "bytes",
|
|
@@ -4202,15 +4202,17 @@ function resolveConfig(config) {
|
|
|
4202
4202
|
*/
|
|
4203
4203
|
function installBashPlusSettings(ctx, entry, onSource) {
|
|
4204
4204
|
let currentSource;
|
|
4205
|
-
|
|
4206
|
-
|
|
4207
|
-
|
|
4208
|
-
|
|
4209
|
-
|
|
4210
|
-
|
|
4211
|
-
|
|
4212
|
-
|
|
4213
|
-
|
|
4205
|
+
ctx.inject(["settings"], (settingsCtx) => {
|
|
4206
|
+
settingsCtx.settings.installSection(ctx, BASH_PLUS_SETTINGS_NS, Config, entry, {
|
|
4207
|
+
setSource: (current) => {
|
|
4208
|
+
currentSource = current;
|
|
4209
|
+
onSource(() => resolveConfig(current()));
|
|
4210
|
+
},
|
|
4211
|
+
onChange: () => {
|
|
4212
|
+
const source = currentSource;
|
|
4213
|
+
if (source) onSource(() => resolveConfig(source()));
|
|
4214
|
+
}
|
|
4215
|
+
});
|
|
4214
4216
|
});
|
|
4215
4217
|
}
|
|
4216
4218
|
//#endregion
|
|
@@ -4533,7 +4535,7 @@ function installBrowserProbeRpc(ctx, deps) {
|
|
|
4533
4535
|
}
|
|
4534
4536
|
};
|
|
4535
4537
|
};
|
|
4536
|
-
disposer = connectionCtx.connection.rpc.handle(TOOL_PLUS_RPC_CHANNEL, handler
|
|
4538
|
+
disposer = connectionCtx.connection.rpc.handle(TOOL_PLUS_RPC_CHANNEL, handler);
|
|
4537
4539
|
} catch {
|
|
4538
4540
|
disposer = void 0;
|
|
4539
4541
|
}
|
|
@@ -14856,7 +14858,7 @@ let specialHandlersPromise;
|
|
|
14856
14858
|
* requires a special handler, so we keep them out of the cold-startup graph.
|
|
14857
14859
|
*/
|
|
14858
14860
|
function loadSpecialHandlers() {
|
|
14859
|
-
specialHandlersPromise ??= import("./scrapers-
|
|
14861
|
+
specialHandlersPromise ??= import("./scrapers-BJ1YemnI.mjs").then((m) => m.specialHandlers);
|
|
14860
14862
|
return specialHandlersPromise;
|
|
14861
14863
|
}
|
|
14862
14864
|
/**
|
|
@@ -26334,7 +26336,8 @@ function apply(ctx, config = {}) {
|
|
|
26334
26336
|
snapshotEnabled: cfg.snapshotEnabled,
|
|
26335
26337
|
rmSafe: cfg.rmSafe,
|
|
26336
26338
|
nonInteractiveEnv: cfg.nonInteractiveEnv,
|
|
26337
|
-
artifactPath: allocateSpillFile()
|
|
26339
|
+
artifactPath: allocateSpillFile(),
|
|
26340
|
+
onMinimizedSave: (text) => saveOriginalText(text)
|
|
26338
26341
|
});
|
|
26339
26342
|
if (result.cancelled && exec.signal.aborted) throw abortError();
|
|
26340
26343
|
if (result.workingDir !== void 0) state.cwd = result.workingDir;
|
|
@@ -26392,7 +26395,8 @@ function apply(ctx, config = {}) {
|
|
|
26392
26395
|
snapshotEnabled: cfg.snapshotEnabled,
|
|
26393
26396
|
rmSafe: cfg.rmSafe,
|
|
26394
26397
|
nonInteractiveEnv: cfg.nonInteractiveEnv,
|
|
26395
|
-
artifactPath: allocateSpillFile()
|
|
26398
|
+
artifactPath: allocateSpillFile(),
|
|
26399
|
+
onMinimizedSave: (text) => saveOriginalText(text)
|
|
26396
26400
|
});
|
|
26397
26401
|
const wallTimeMs = performance.now() - startedAt;
|
|
26398
26402
|
if (result.cancelled && exec.signal.aborted) throw abortError();
|
|
@@ -3,7 +3,7 @@ __installBunShim();
|
|
|
3
3
|
import { n as fs_promises_shim_exports } from "./fs-promises-shim-Bx0fpxuk.mjs";
|
|
4
4
|
import { B as USER_AGENT, G as getDocsRsCacheDir, N as formatNumber, P as $env, T as warn, c as combineSignals, j as formatBytes, l as exec, s as Snowflake, x as parseFrontmatter, y as isEnoent } from "./src-D_e1qMwi.mjs";
|
|
5
5
|
import { V as tryParseJson } from "./utils-fnV2zzp3.mjs";
|
|
6
|
-
import { a as fetchBinary, c as getParallelExtractContent, i as convertWithMarkit, l as ensureTool, m as settings, n as asRecord, o as extractWithParallel, r as asString, s as findParallelApiKey, t as asNumber } from "./utils-
|
|
6
|
+
import { a as fetchBinary, c as getParallelExtractContent, i as convertWithMarkit, l as ensureTool, m as settings, n as asRecord, o as extractWithParallel, r as asString, s as findParallelApiKey, t as asNumber } from "./utils-DEUxgLCs.mjs";
|
|
7
7
|
import { n as isRecord } from "./type-guards-B9VVjRDK.mjs";
|
|
8
8
|
import { r as throwIfAborted, t as ToolAbortError } from "./tool-errors-DoyxivAR.mjs";
|
|
9
9
|
import { c as getLocalizedText, d as looksLikeHtml, i as decodeHtmlEntities, l as htmlToBasicMarkdown, o as formatIsoDate, r as buildResult, s as formatMediaDuration, u as loadPage } from "./types-BUO0JXO-.mjs";
|
|
@@ -7202,7 +7202,7 @@ const settings = {
|
|
|
7202
7202
|
};
|
|
7203
7203
|
//#endregion
|
|
7204
7204
|
//#region package.json
|
|
7205
|
-
var version = "0.1.
|
|
7205
|
+
var version = "0.1.3";
|
|
7206
7206
|
/** `.tmp` files older than this are treated as orphaned writes and swept. */
|
|
7207
7207
|
const TMP_ORPHAN_MAX_AGE_MS = 3e5;
|
|
7208
7208
|
function markitConversionCacheKey(bytes, extension) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xiaoso/dsh-tool-plus",
|
|
3
3
|
"description": "Oh My Pi bash runtime ported as a deepseek-harness tool plugin: persistent shell session, output minimizer, managed background jobs, command interception",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.3",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"deepseek-harness",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"type": "module",
|
|
31
31
|
"publishConfig": {
|
|
32
32
|
"access": "public",
|
|
33
|
-
"tag": "
|
|
33
|
+
"tag": "latest"
|
|
34
34
|
},
|
|
35
35
|
"engines": {
|
|
36
36
|
"node": "^22.19.0 || >=24.0.0"
|
|
@@ -64,7 +64,6 @@
|
|
|
64
64
|
},
|
|
65
65
|
"client": {
|
|
66
66
|
"inject": [
|
|
67
|
-
"@deepseek-ai/dsh-client-runtime",
|
|
68
67
|
"@deepseek-ai/dsh-client-locale",
|
|
69
68
|
"@deepseek-ai/dsh-client-ui-settings"
|
|
70
69
|
],
|
|
@@ -80,26 +79,26 @@
|
|
|
80
79
|
"postinstall": "node scripts/patch-pi-natives.mjs"
|
|
81
80
|
},
|
|
82
81
|
"peerDependencies": {
|
|
83
|
-
"@deepseek-ai/cordis": "
|
|
84
|
-
"@deepseek-ai/dsh-agent": "
|
|
85
|
-
"@deepseek-ai/dsh-attachment": "
|
|
86
|
-
"@deepseek-ai/dsh-client-connection": "
|
|
87
|
-
"@deepseek-ai/dsh-fs": "
|
|
88
|
-
"@deepseek-ai/dsh-jobs": "
|
|
89
|
-
"@deepseek-ai/dsh-llm": "
|
|
90
|
-
"@deepseek-ai/dsh-sandbox": "
|
|
91
|
-
"@deepseek-ai/dsh-session": "
|
|
92
|
-
"@deepseek-ai/dsh-settings": "
|
|
93
|
-
"@deepseek-ai/dsh-shell": "
|
|
94
|
-
"@deepseek-ai/dsh-shell-env": "
|
|
95
|
-
"@deepseek-ai/dsh-system-prompt": "
|
|
96
|
-
"@deepseek-ai/dsh-tools": "
|
|
82
|
+
"@deepseek-ai/cordis": "4.0.2",
|
|
83
|
+
"@deepseek-ai/dsh-agent": "0.1.2-rc.1",
|
|
84
|
+
"@deepseek-ai/dsh-attachment": "0.1.2-rc.1",
|
|
85
|
+
"@deepseek-ai/dsh-client-connection": "0.1.2-rc.1",
|
|
86
|
+
"@deepseek-ai/dsh-fs": "0.1.2-rc.1",
|
|
87
|
+
"@deepseek-ai/dsh-jobs": "0.1.2-rc.1",
|
|
88
|
+
"@deepseek-ai/dsh-llm": "0.1.2-rc.1",
|
|
89
|
+
"@deepseek-ai/dsh-sandbox": "0.1.2-rc.1",
|
|
90
|
+
"@deepseek-ai/dsh-session": "0.1.2-rc.1",
|
|
91
|
+
"@deepseek-ai/dsh-settings": "0.1.2-rc.1",
|
|
92
|
+
"@deepseek-ai/dsh-shell": "0.1.2-rc.1",
|
|
93
|
+
"@deepseek-ai/dsh-shell-env": "0.1.2-rc.1",
|
|
94
|
+
"@deepseek-ai/dsh-system-prompt": "0.1.2-rc.1",
|
|
95
|
+
"@deepseek-ai/dsh-tools": "0.1.2-rc.1"
|
|
97
96
|
},
|
|
98
97
|
"optionalPeerDependencies": {
|
|
99
98
|
"sharp": ">=0.33"
|
|
100
99
|
},
|
|
101
100
|
"dependencies": {
|
|
102
|
-
"@deepseek-ai/schemastery": "
|
|
101
|
+
"@deepseek-ai/schemastery": "3.18.2",
|
|
103
102
|
"@oh-my-pi/omptype": "17.3.5",
|
|
104
103
|
"@oh-my-pi/pi-agent-core": "17.3.5",
|
|
105
104
|
"@oh-my-pi/pi-ai": "17.3.5",
|
|
@@ -113,27 +112,27 @@
|
|
|
113
112
|
"yaml": "^2.9.0"
|
|
114
113
|
},
|
|
115
114
|
"devDependencies": {
|
|
116
|
-
"@deepseek-ai/cordis": "
|
|
117
|
-
"@deepseek-ai/dsh-agent": "
|
|
118
|
-
"@deepseek-ai/dsh-client-connection": "
|
|
119
|
-
"@deepseek-ai/dsh-client-locale": "
|
|
120
|
-
"@deepseek-ai/dsh-client-
|
|
121
|
-
"@deepseek-ai/dsh-client-ui-
|
|
122
|
-
"@deepseek-ai/dsh-client-ui-settings": "
|
|
123
|
-
"@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.
|
|
124
|
-
"@deepseek-ai/dsh-client-ui-slots": "
|
|
125
|
-
"@deepseek-ai/dsh-fs-local": "0.1.
|
|
126
|
-
"@deepseek-ai/dsh-jobs": "
|
|
127
|
-
"@deepseek-ai/dsh-jobs-local": "
|
|
128
|
-
"@deepseek-ai/dsh-llm": "
|
|
129
|
-
"@deepseek-ai/dsh-session": "
|
|
130
|
-
"@deepseek-ai/dsh-settings": "
|
|
131
|
-
"@deepseek-ai/dsh-shell": "
|
|
132
|
-
"@deepseek-ai/dsh-shell-env": "
|
|
133
|
-
"@deepseek-ai/dsh-system-prompt": "
|
|
134
|
-
"@deepseek-ai/dsh-tool-jobs": "
|
|
135
|
-
"@deepseek-ai/dsh-tool-str-replace-editor": "0.1.
|
|
136
|
-
"@deepseek-ai/dsh-tools": "
|
|
115
|
+
"@deepseek-ai/cordis": "4.0.2",
|
|
116
|
+
"@deepseek-ai/dsh-agent": "0.1.2-rc.1",
|
|
117
|
+
"@deepseek-ai/dsh-client-connection": "0.1.2-rc.1",
|
|
118
|
+
"@deepseek-ai/dsh-client-locale": "0.1.2-rc.1",
|
|
119
|
+
"@deepseek-ai/dsh-client-ui-primitives": "0.1.2-rc.1",
|
|
120
|
+
"@deepseek-ai/dsh-client-ui-renderer": "0.1.2-rc.1",
|
|
121
|
+
"@deepseek-ai/dsh-client-ui-settings": "0.1.2-rc.1",
|
|
122
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.2-rc.1",
|
|
123
|
+
"@deepseek-ai/dsh-client-ui-slots": "0.1.2-rc.1",
|
|
124
|
+
"@deepseek-ai/dsh-fs-local": "0.1.2-rc.1",
|
|
125
|
+
"@deepseek-ai/dsh-jobs": "0.1.2-rc.1",
|
|
126
|
+
"@deepseek-ai/dsh-jobs-local": "0.1.2-rc.1",
|
|
127
|
+
"@deepseek-ai/dsh-llm": "0.1.2-rc.1",
|
|
128
|
+
"@deepseek-ai/dsh-session": "0.1.2-rc.1",
|
|
129
|
+
"@deepseek-ai/dsh-settings": "0.1.2-rc.1",
|
|
130
|
+
"@deepseek-ai/dsh-shell": "0.1.2-rc.1",
|
|
131
|
+
"@deepseek-ai/dsh-shell-env": "0.1.2-rc.1",
|
|
132
|
+
"@deepseek-ai/dsh-system-prompt": "0.1.2-rc.1",
|
|
133
|
+
"@deepseek-ai/dsh-tool-jobs": "0.1.2-rc.1",
|
|
134
|
+
"@deepseek-ai/dsh-tool-str-replace-editor": "0.1.2-rc.1",
|
|
135
|
+
"@deepseek-ai/dsh-tools": "0.1.2-rc.1",
|
|
137
136
|
"@types/node": "^22.19.0",
|
|
138
137
|
"@types/react": "^19.0.0",
|
|
139
138
|
"@types/react-dom": "^19.0.0",
|
package/presets/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xiaoso/dsh-tool-plus-presets",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Agent-preset installer for dsh-tool-plus: installs the standard / PTC enhanced preset templates into a DeepSeek Harness home.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"type": "module",
|
|
26
26
|
"publishConfig": {
|
|
27
27
|
"access": "public",
|
|
28
|
-
"tag": "
|
|
28
|
+
"tag": "latest"
|
|
29
29
|
},
|
|
30
30
|
"bin": {
|
|
31
31
|
"dsh-tool-plus-presets": "./install-presets.mjs"
|