deepline 0.3.414 → 0.3.416
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/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/cli/auth-BNQP4UYQ.js +40 -0
- package/dist/cli/{auth-5QG4TOA6.mjs → auth-FLYZAZ7I.mjs} +4 -4
- package/dist/cli/{billing-W7YO6VXH.js → billing-SVGZSMBY.js} +73 -73
- package/dist/cli/{billing-JV3HCOMG.mjs → billing-XZ62L6ZE.mjs} +4 -4
- package/dist/cli/{chunk-PK55NFM5.js → chunk-2DRO4YWM.js} +2 -2
- package/dist/cli/{chunk-S6ZBXS7N.mjs → chunk-2MQJODFQ.mjs} +1 -1
- package/dist/cli/{chunk-QVBVSC3M.js → chunk-4R3TJDWD.js} +8 -8
- package/dist/cli/{chunk-VOTKMPYY.mjs → chunk-6GYQG6V3.mjs} +7 -3
- package/dist/cli/{chunk-H5GTXEGI.mjs → chunk-7OLAGY3W.mjs} +4 -4
- package/dist/cli/{chunk-NOGPMTF5.mjs → chunk-DBMALDT3.mjs} +8 -8
- package/dist/cli/{chunk-LI2LTEO4.mjs → chunk-DT36JAAX.mjs} +2 -2
- package/dist/cli/{chunk-ZEQ3N6SI.js → chunk-E5FNJE3Y.js} +4 -4
- package/dist/cli/{chunk-UGQLBLSZ.mjs → chunk-ENBTCBGT.mjs} +23 -14
- package/dist/cli/{chunk-L3DLOICI.mjs → chunk-ERPU6HBQ.mjs} +3 -3
- package/dist/cli/{chunk-XPOIHVTN.js → chunk-ESUBIEVT.js} +6 -6
- package/dist/cli/{chunk-EWDWMTTD.js → chunk-F5KJFBDA.js} +1 -1
- package/dist/cli/{chunk-5S4QRLRC.mjs → chunk-FFEA6KAB.mjs} +2 -2
- package/dist/cli/{chunk-RYWFCSGX.mjs → chunk-G3WJWD4R.mjs} +1 -1
- package/dist/cli/{chunk-URBOSCO6.js → chunk-LFUGXKJW.js} +20 -20
- package/dist/cli/{chunk-N3EF5WQV.js → chunk-MRL2OMZY.js} +10 -10
- package/dist/cli/{chunk-HSYVA2JK.mjs → chunk-MT7VPFMN.mjs} +2 -2
- package/dist/cli/{chunk-3PBK7PHE.mjs → chunk-NPFMAFUC.mjs} +1 -1
- package/dist/cli/{chunk-JR4FDOWR.js → chunk-NWPC3FUA.js} +28 -19
- package/dist/cli/{chunk-MALNVMG6.mjs → chunk-PH6OXQC7.mjs} +1 -1
- package/dist/cli/{chunk-OKKLH4QY.mjs → chunk-Q6MUMX2G.mjs} +2 -2
- package/dist/cli/{chunk-J2GD6PDT.js → chunk-TOIDV6Q4.js} +50 -50
- package/dist/cli/{chunk-RHOY4RXI.js → chunk-TXLZ6BJC.js} +26 -26
- package/dist/cli/{chunk-4CPRZPRQ.js → chunk-UJTWIOQK.js} +6 -6
- package/dist/cli/{chunk-VJRAFJ6H.js → chunk-UXLXZN2F.js} +2 -2
- package/dist/cli/{chunk-MH6H63HF.js → chunk-WL3MI252.js} +35 -35
- package/dist/cli/{chunk-M2V34XOG.mjs → chunk-XP6LSFCW.mjs} +5 -5
- package/dist/cli/{chunk-QWLGBYTB.mjs → chunk-XUMHZPE3.mjs} +1 -1
- package/dist/cli/{chunk-ODA4AZM3.js → chunk-YCAMTIYM.js} +79 -79
- package/dist/cli/{chunk-OEHMER3F.js → chunk-YK3XHX7G.js} +16 -16
- package/dist/cli/{chunk-BXWLG55T.js → chunk-ZCO7R65D.js} +56 -52
- package/dist/cli/{chunk-EFD5CW26.mjs → chunk-ZMQTLPLJ.mjs} +1 -1
- package/dist/cli/{csv-HH5HBH2J.mjs → csv-4TAHSCJO.mjs} +3 -3
- package/dist/cli/{csv-EO2L4TEE.js → csv-X72WTTMT.js} +12 -12
- package/dist/cli/{db-MUXVX2BC.js → db-3LIMAM2U.js} +25 -25
- package/dist/cli/{db-Y7CREGF3.mjs → db-CK3WE7QC.mjs} +4 -4
- package/dist/cli/{describe-4P76LT4U.mjs → describe-FW6XZCFK.mjs} +12 -12
- package/dist/cli/{describe-66HDJGQI.js → describe-H2Z2VKU2.js} +16 -16
- package/dist/cli/{executions-SOEK54UR.mjs → executions-VXGO3GSE.mjs} +4 -4
- package/dist/cli/{executions-HKGTLNX5.js → executions-X7SXKMAI.js} +6 -6
- package/dist/cli/{feedback-TLABM3DG.js → feedback-6I3NFUPV.js} +7 -7
- package/dist/cli/{feedback-NX64K5CR.mjs → feedback-KTDQHUNJ.mjs} +3 -3
- package/dist/cli/git-LLP4T6XB.js +24 -0
- package/dist/cli/{git-Y25E2ZJC.mjs → git-ODZASGIK.mjs} +4 -4
- package/dist/cli/index.js +131 -131
- package/dist/cli/index.mjs +36 -36
- package/dist/cli/{legacy-noops-EXFCXCRK.js → legacy-noops-HLVQGZ72.js} +7 -7
- package/dist/cli/{legacy-noops-RRMXZZ4S.mjs → legacy-noops-KNGT6U3L.mjs} +4 -4
- package/dist/cli/{monitors-FB75AVWA.js → monitors-3F5EZCMB.js} +84 -84
- package/dist/cli/{monitors-CCKCBND7.mjs → monitors-JLGADUE5.mjs} +4 -4
- package/dist/cli/{org-KDPXHQPC.mjs → org-D7AW6LIR.mjs} +4 -4
- package/dist/cli/{org-SQQG44XI.js → org-Z4LPCJII.js} +64 -64
- package/dist/cli/{play-HPQEDJEP.mjs → play-MO3SAHDS.mjs} +10 -10
- package/dist/cli/{play-CSKSDDQS.js → play-UBNDV57A.js} +283 -283
- package/dist/cli/{providers-TFVCFP7J.mjs → providers-QCBNQY4A.mjs} +4 -4
- package/dist/cli/{providers-7FDWGH3C.js → providers-SL6ZSEDI.js} +7 -7
- package/dist/cli/{quickstart-2J67PING.mjs → quickstart-K7J4YOTE.mjs} +3 -3
- package/dist/cli/{quickstart-JQRTIIIZ.js → quickstart-YGFVF6VL.js} +5 -5
- package/dist/cli/{search-7ZA7UIVM.mjs → search-DVE6TKQ3.mjs} +5 -5
- package/dist/cli/search-V4HNFZRE.js +30 -0
- package/dist/cli/{secrets-J676GB6Q.js → secrets-G7ZMCH5J.js} +13 -13
- package/dist/cli/{secrets-ZQY5GO4T.mjs → secrets-JOVBXCUR.mjs} +4 -4
- package/dist/cli/{sessions-OP2352DC.mjs → sessions-NA5POIR5.mjs} +4 -4
- package/dist/cli/{sessions-AVICKLMK.js → sessions-QQV7FO4Y.js} +5 -5
- package/dist/cli/{settings-QNILCEH6.mjs → settings-AM44HC2C.mjs} +8 -8
- package/dist/cli/{settings-EWKNDCGF.js → settings-XGFHXFCJ.js} +75 -75
- package/dist/cli/{setup-IHILOCOK.js → setup-DA4TSWCY.js} +42 -42
- package/dist/cli/{setup-4NDX6UAI.mjs → setup-RUBLF452.mjs} +7 -7
- package/dist/cli/skills-6AQTCBTF.js +29 -0
- package/dist/cli/{skills-H73NL3VP.mjs → skills-TRG55YOF.mjs} +5 -5
- package/dist/cli/{tools-ZFPBY4Q2.mjs → tools-CEEA7DU4.mjs} +12 -12
- package/dist/cli/tools-JLPTH7TF.js +44 -0
- package/dist/cli/update-EKEBZDIX.js +31 -0
- package/dist/cli/{update-XULEC376.mjs → update-Y5GSWR67.mjs} +7 -7
- package/dist/cli/{workflow-OD5XZHCL.mjs → workflow-74I6RNJR.mjs} +5 -5
- package/dist/cli/{workflow-JX4WSBYH.js → workflow-D2VHQKJB.js} +15 -15
- package/dist/index.js +6 -6
- package/dist/index.mjs +3 -3
- package/dist/install-integrity.json +78 -78
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/package.json +1 -1
- package/dist/cli/auth-5A3Z4LNL.js +0 -40
- package/dist/cli/git-K55QWG6X.js +0 -24
- package/dist/cli/search-O3PYDXOZ.js +0 -30
- package/dist/cli/skills-TDL7SEFT.js +0 -29
- package/dist/cli/tools-GPFPJWWA.js +0 -44
- package/dist/cli/update-VR6EWUUT.js +0 -31
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkUXLXZN2Fjs = require('./chunk-UXLXZN2F.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkWL3MI252js = require('./chunk-WL3MI252.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkZCO7R65Djs = require('./chunk-ZCO7R65D.js');
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
13
|
+
var _chunkUJTWIOQKjs = require('./chunk-UJTWIOQK.js');
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkE5FNJE3Yjs = require('./chunk-E5FNJE3Y.js');
|
|
17
17
|
|
|
18
18
|
// src/cli/commands/update.ts
|
|
19
19
|
var _child_process = require('child_process');
|
|
@@ -495,7 +495,7 @@ function normalizedNpmPrefix(value) {
|
|
|
495
495
|
}
|
|
496
496
|
function resolveNpmGlobalPrefix(env) {
|
|
497
497
|
try {
|
|
498
|
-
const plan =
|
|
498
|
+
const plan = _chunkZCO7R65Djs.resolveShellSpawn.call(void 0,
|
|
499
499
|
"npm",
|
|
500
500
|
["prefix", "-g"],
|
|
501
501
|
process.platform,
|
|
@@ -556,8 +556,8 @@ function resolveUpdatePlan(options = {}) {
|
|
|
556
556
|
const npmGlobalPrefix = options.npmGlobalPrefix !== void 0 ? options.npmGlobalPrefix : resolveNpmGlobalPrefix(env);
|
|
557
557
|
const hasVerifiedNpmOwnership = inferredInstallPrefix !== null && normalizedNpmPrefix(inferredInstallPrefix) === normalizedNpmPrefix(npmGlobalPrefix);
|
|
558
558
|
const installPrefix = options.requireVerifiedNpmOwnership ? hasVerifiedNpmOwnership ? inferredInstallPrefix : null : inferredInstallPrefix;
|
|
559
|
-
const npmVersion = options.npmVersion === void 0 ?
|
|
560
|
-
const npmGlobalInstallFlags =
|
|
559
|
+
const npmVersion = options.npmVersion === void 0 ? _chunkUXLXZN2Fjs.readNpmVersion.call(void 0, env) : options.npmVersion;
|
|
560
|
+
const npmGlobalInstallFlags = _chunkUXLXZN2Fjs.npmSupportsAllowScripts.call(void 0, npmVersion) ? [...NPM_SDK_INSTALL_COMMON_FLAGS, "--allow-scripts=esbuild"] : NPM_SDK_INSTALL_COMMON_FLAGS;
|
|
561
561
|
const args = installPrefix ? [
|
|
562
562
|
"install",
|
|
563
563
|
"-g",
|
|
@@ -567,7 +567,7 @@ function resolveUpdatePlan(options = {}) {
|
|
|
567
567
|
packageSpec
|
|
568
568
|
] : ["install", "-g", ...npmGlobalInstallFlags, packageSpec];
|
|
569
569
|
const fallbackRegistryUrl = options.npmFallbackRegistryUrl !== void 0 ? options.npmFallbackRegistryUrl : publicNpmFallbackRegistryUrl(
|
|
570
|
-
_optionalChain([env, 'access', _22 => _22.DEEPLINE_HOST_URL, 'optionalAccess', _23 => _23.trim, 'call', _24 => _24()]) ||
|
|
570
|
+
_optionalChain([env, 'access', _22 => _22.DEEPLINE_HOST_URL, 'optionalAccess', _23 => _23.trim, 'call', _24 => _24()]) || _chunkE5FNJE3Yjs.autoDetectBaseUrl.call(void 0, )
|
|
571
571
|
);
|
|
572
572
|
return {
|
|
573
573
|
kind: "npm-global",
|
|
@@ -816,7 +816,7 @@ function sidecarInstallFailure(versionDir) {
|
|
|
816
816
|
function runCommand(command, args, env = process.env) {
|
|
817
817
|
return new Promise((resolveResult) => {
|
|
818
818
|
let output = "";
|
|
819
|
-
const plan =
|
|
819
|
+
const plan = _chunkZCO7R65Djs.resolveShellSpawn.call(void 0, command, args, process.platform, env);
|
|
820
820
|
const child = _child_process.spawn.call(void 0, plan.command, plan.args, {
|
|
821
821
|
stdio: ["inherit", "pipe", "pipe"],
|
|
822
822
|
shell: plan.shell,
|
|
@@ -1199,14 +1199,14 @@ async function publishedVersionSupportsPin(version, fallbackRegistryUrl) {
|
|
|
1199
1199
|
throw _nullishCoalesce(lastError, () => ( new Error("No npm registry was available")));
|
|
1200
1200
|
}
|
|
1201
1201
|
async function runUpdateCommand(options, dependencies = {}) {
|
|
1202
|
-
const detectBaseUrl = _nullishCoalesce(dependencies.detectBaseUrl, () => (
|
|
1202
|
+
const detectBaseUrl = _nullishCoalesce(dependencies.detectBaseUrl, () => ( _chunkE5FNJE3Yjs.autoDetectBaseUrl));
|
|
1203
1203
|
const resolvePlan = _nullishCoalesce(dependencies.resolvePlan, () => ( resolveUpdatePlan));
|
|
1204
1204
|
const runPlan = _nullishCoalesce(dependencies.runPlan, () => ( runUpdatePlan));
|
|
1205
1205
|
const syncSkills = _nullishCoalesce(dependencies.syncSkillsIfNeeded, () => ( (async () => {
|
|
1206
1206
|
const originalWrite = process.stdout.write.bind(process.stdout);
|
|
1207
1207
|
process.stdout.write = (() => true);
|
|
1208
1208
|
try {
|
|
1209
|
-
const exitCode = await
|
|
1209
|
+
const exitCode = await _chunkWL3MI252js.runSkillsCommand.call(void 0, { json: true });
|
|
1210
1210
|
if (exitCode !== 0) {
|
|
1211
1211
|
throw new Error(
|
|
1212
1212
|
`Deepline skills update failed with exit ${exitCode}.`
|
|
@@ -1277,11 +1277,11 @@ async function runUpdateCommand(options, dependencies = {}) {
|
|
|
1277
1277
|
]
|
|
1278
1278
|
};
|
|
1279
1279
|
if (options.json && !options.executeWithJson) {
|
|
1280
|
-
|
|
1280
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0, { ...plan, render }, { json: true });
|
|
1281
1281
|
return 0;
|
|
1282
1282
|
}
|
|
1283
1283
|
if (options.printCommand) {
|
|
1284
|
-
|
|
1284
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0,
|
|
1285
1285
|
{
|
|
1286
1286
|
...plan,
|
|
1287
1287
|
render: {
|
|
@@ -1294,7 +1294,7 @@ async function runUpdateCommand(options, dependencies = {}) {
|
|
|
1294
1294
|
return 0;
|
|
1295
1295
|
}
|
|
1296
1296
|
if (plan.kind === "source" || plan.kind === "homebrew") {
|
|
1297
|
-
|
|
1297
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0, { ...plan, render }, { json: false });
|
|
1298
1298
|
return 0;
|
|
1299
1299
|
}
|
|
1300
1300
|
stderr.write(`Updating Deepline SDK/CLI with: ${plan.manualCommand}
|
|
@@ -1324,7 +1324,7 @@ To retry with full installer output, run: deepline skills
|
|
|
1324
1324
|
);
|
|
1325
1325
|
}
|
|
1326
1326
|
if (options.executeWithJson && options.json) {
|
|
1327
|
-
|
|
1327
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0,
|
|
1328
1328
|
{
|
|
1329
1329
|
ok: true,
|
|
1330
1330
|
pinnedVersion
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class;
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkUJTWIOQKjs = require('./chunk-UJTWIOQK.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -17,13 +17,13 @@ var _chunk4CPRZPRQjs = require('./chunk-4CPRZPRQ.js');
|
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _chunkE5FNJE3Yjs = require('./chunk-E5FNJE3Y.js');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
var _chunkPPDBRJRWjs = require('./chunk-PPDBRJRW.js');
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
26
|
+
var _chunkF5KJFBDAjs = require('./chunk-F5KJFBDA.js');
|
|
27
27
|
|
|
28
28
|
// src/compat.ts
|
|
29
29
|
var _crypto = require('crypto');
|
|
@@ -58,7 +58,7 @@ function shouldSkipCompatibilityCheck() {
|
|
|
58
58
|
return value === "1" || value === "true" || value === "yes";
|
|
59
59
|
}
|
|
60
60
|
function sdkCompatibilityCachePath(baseUrl, homeDir = _optionalChain([process, 'access', _7 => _7.env, 'access', _8 => _8.HOME, 'optionalAccess', _9 => _9.trim, 'call', _10 => _10()]) || _os.homedir.call(void 0, )) {
|
|
61
|
-
return _path.join.call(void 0,
|
|
61
|
+
return _path.join.call(void 0, _chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl, homeDir), "compat-cache.json");
|
|
62
62
|
}
|
|
63
63
|
function legacySdkCompatibilityCachePath(homeDir = _optionalChain([process, 'access', _11 => _11.env, 'access', _12 => _12.HOME, 'optionalAccess', _13 => _13.trim, 'call', _14 => _14()]) || _os.homedir.call(void 0, )) {
|
|
64
64
|
return _path.join.call(void 0, homeDir, ".cache", "deepline", "sdk-compat-cache.json");
|
|
@@ -66,9 +66,9 @@ function legacySdkCompatibilityCachePath(homeDir = _optionalChain([process, 'acc
|
|
|
66
66
|
function compatibilityCacheKey(baseUrl, command, skillsVersion) {
|
|
67
67
|
return JSON.stringify({
|
|
68
68
|
baseUrl: baseUrl.replace(/\/$/, ""),
|
|
69
|
-
version:
|
|
70
|
-
apiContract:
|
|
71
|
-
apiMajor:
|
|
69
|
+
version: _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
70
|
+
apiContract: _chunkE5FNJE3Yjs.SDK_API_CONTRACT,
|
|
71
|
+
apiMajor: _chunkE5FNJE3Yjs.SDK_API_MAJOR,
|
|
72
72
|
command: _optionalChain([command, 'optionalAccess', _15 => _15.trim, 'call', _16 => _16()]) || null,
|
|
73
73
|
skillsVersion: _nullishCoalesce(skillsVersion, () => ( null))
|
|
74
74
|
});
|
|
@@ -76,8 +76,8 @@ function compatibilityCacheKey(baseUrl, command, skillsVersion) {
|
|
|
76
76
|
function legacyCompatibilityCacheKey(baseUrl, command) {
|
|
77
77
|
return JSON.stringify({
|
|
78
78
|
baseUrl: baseUrl.replace(/\/$/, ""),
|
|
79
|
-
version:
|
|
80
|
-
apiContract:
|
|
79
|
+
version: _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
80
|
+
apiContract: _chunkE5FNJE3Yjs.SDK_API_CONTRACT,
|
|
81
81
|
command: _optionalChain([command, 'optionalAccess', _17 => _17.trim, 'call', _18 => _18()]) || null
|
|
82
82
|
});
|
|
83
83
|
}
|
|
@@ -102,7 +102,7 @@ function isSavedWithin(savedAt, windowMs, now) {
|
|
|
102
102
|
}
|
|
103
103
|
var UPDATE_ADVISORY_INTERVAL_MS = 24 * 60 * 60 * 1e3;
|
|
104
104
|
function claimUpdateAdvisory(baseUrl, now = Date.now()) {
|
|
105
|
-
const path = _path.join.call(void 0,
|
|
105
|
+
const path = _path.join.call(void 0, _chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl), "update-advisory.json");
|
|
106
106
|
try {
|
|
107
107
|
const { shownAt } = JSON.parse(_fs.readFileSync.call(void 0, path, "utf8"));
|
|
108
108
|
if (isSavedWithin(shownAt, UPDATE_ADVISORY_INTERVAL_MS, now)) return false;
|
|
@@ -186,7 +186,7 @@ async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
|
186
186
|
);
|
|
187
187
|
try {
|
|
188
188
|
const url = new URL("/api/v2/sdk/compat", baseUrl);
|
|
189
|
-
url.searchParams.set("version",
|
|
189
|
+
url.searchParams.set("version", _chunkE5FNJE3Yjs.SDK_VERSION);
|
|
190
190
|
if (_optionalChain([options, 'access', _27 => _27.command, 'optionalAccess', _28 => _28.trim, 'call', _29 => _29()])) {
|
|
191
191
|
url.searchParams.set("command", options.command.trim());
|
|
192
192
|
}
|
|
@@ -194,7 +194,7 @@ async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
|
194
194
|
url.searchParams.set("skills_version", _nullishCoalesce(options.skillsVersion, () => ( "")));
|
|
195
195
|
url.searchParams.set(
|
|
196
196
|
"skills_cli_capability",
|
|
197
|
-
String(
|
|
197
|
+
String(_chunkF5KJFBDAjs.SDK_RELEASE.packageCapabilities.skillsGuidance)
|
|
198
198
|
);
|
|
199
199
|
}
|
|
200
200
|
if (options.catalog) {
|
|
@@ -206,14 +206,14 @@ async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
|
206
206
|
const response = await fetch(url, {
|
|
207
207
|
method: "GET",
|
|
208
208
|
headers: {
|
|
209
|
-
...
|
|
210
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
211
|
-
"X-Deepline-SDK-Version":
|
|
212
|
-
"X-Deepline-API-Major": String(
|
|
213
|
-
"X-Deepline-API-Contract":
|
|
209
|
+
..._chunkE5FNJE3Yjs.deploymentProtectionHeaders.call(void 0, ),
|
|
210
|
+
"User-Agent": `deepline-ts-sdk/${_chunkE5FNJE3Yjs.SDK_VERSION}`,
|
|
211
|
+
"X-Deepline-SDK-Version": _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
212
|
+
"X-Deepline-API-Major": String(_chunkE5FNJE3Yjs.SDK_API_MAJOR),
|
|
213
|
+
"X-Deepline-API-Contract": _chunkE5FNJE3Yjs.SDK_API_CONTRACT,
|
|
214
214
|
"X-Deepline-CLI-Update-Preferences": "1",
|
|
215
215
|
"X-Deepline-CLI-Auto-Update-Capability": SDK_CLI_AUTO_UPDATE_CAPABILITY,
|
|
216
|
-
...options.catalog ? { Authorization: `Bearer ${
|
|
216
|
+
...options.catalog ? { Authorization: `Bearer ${_chunkE5FNJE3Yjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl)}` } : {},
|
|
217
217
|
..._optionalChain([options, 'access', _30 => _30.catalog, 'optionalAccess', _31 => _31.cliInvocationId]) ? { "X-Deepline-CLI-Invocation-ID": options.catalog.cliInvocationId } : {}
|
|
218
218
|
},
|
|
219
219
|
signal: controller.signal
|
|
@@ -340,6 +340,10 @@ var DEFAULT_V1_SKILL_NAMES = [
|
|
|
340
340
|
"deepline-research",
|
|
341
341
|
"deepline-scoring",
|
|
342
342
|
"find-qualified-titles",
|
|
343
|
+
// Retired recipe shortcut: lookup guidance is now one rule in `deepline-gtm`.
|
|
344
|
+
// Kept as a stub because installed CLIs list it and refuse to sync any skill
|
|
345
|
+
// when the published index lacks a listed name. Move to
|
|
346
|
+
// LEGACY_SKILL_NAMES_TO_REMOVE once those CLIs are out of the field.
|
|
343
347
|
"linkedin-url-lookup",
|
|
344
348
|
// Deprecated alias for `deepline-scoring`, kept installable so saved prompts
|
|
345
349
|
// and scripts using `/niche-signal-discovery` keep routing to the renamed
|
|
@@ -370,7 +374,7 @@ function skillsSourceUrl(baseUrl) {
|
|
|
370
374
|
function buildSkillsAddArgs(baseUrl, skillName, options = {}) {
|
|
371
375
|
const skillNames = Array.isArray(skillName) ? skillName : [skillName];
|
|
372
376
|
const [firstSkillName, ...extraSkillNames] = skillNames;
|
|
373
|
-
const agents = _nullishCoalesce(options.agents, () => (
|
|
377
|
+
const agents = _nullishCoalesce(options.agents, () => ( _chunkE5FNJE3Yjs.DEFAULT_SKILL_AGENTS));
|
|
374
378
|
const values = {
|
|
375
379
|
skills_index_url: skillsIndexUrl(baseUrl),
|
|
376
380
|
skills_source_url: skillsSourceUrl(baseUrl),
|
|
@@ -409,7 +413,7 @@ var CliProgress = (_class = class {
|
|
|
409
413
|
|
|
410
414
|
// --json output is one JSON document: progress never renders under it.
|
|
411
415
|
constructor(enabled) {;_class.prototype.__init.call(this);_class.prototype.__init2.call(this);_class.prototype.__init3.call(this);_class.prototype.__init4.call(this);_class.prototype.__init5.call(this);_class.prototype.__init6.call(this);_class.prototype.__init7.call(this);
|
|
412
|
-
this.enabled = enabled && !
|
|
416
|
+
this.enabled = enabled && !_chunkUJTWIOQKjs.isJsonOutputMode.call(void 0, );
|
|
413
417
|
}
|
|
414
418
|
phase(message) {
|
|
415
419
|
if (!this.enabled || this.lastMessage === message) {
|
|
@@ -434,7 +438,7 @@ var CliProgress = (_class = class {
|
|
|
434
438
|
this.settle("\u2717");
|
|
435
439
|
}
|
|
436
440
|
writeLogLine(line) {
|
|
437
|
-
if (
|
|
441
|
+
if (_chunkUJTWIOQKjs.isJsonOutputMode.call(void 0, )) return;
|
|
438
442
|
if (!this.enabled) {
|
|
439
443
|
process.stderr.write(`${line}
|
|
440
444
|
`);
|
|
@@ -736,7 +740,7 @@ function buildEnvironmentContext() {
|
|
|
736
740
|
node_version: process.version,
|
|
737
741
|
runtime: "Node.js",
|
|
738
742
|
hostname: _os.hostname.call(void 0, ),
|
|
739
|
-
agent_runtime:
|
|
743
|
+
agent_runtime: _chunkE5FNJE3Yjs.detectAgentRuntime.call(void 0, )
|
|
740
744
|
};
|
|
741
745
|
for (const key of ["CLAUDE_CODE_REMOTE", "DEEPLINE_PLUGIN_MODE"]) {
|
|
742
746
|
const normalized = _optionalChain([process, 'access', _60 => _60.env, 'access', _61 => _61[key], 'optionalAccess', _62 => _62.trim, 'call', _63 => _63()]);
|
|
@@ -758,15 +762,15 @@ function buildEnvironmentContext() {
|
|
|
758
762
|
}
|
|
759
763
|
function failureReportHeaders(apiKey) {
|
|
760
764
|
return {
|
|
761
|
-
...
|
|
765
|
+
..._chunkE5FNJE3Yjs.deploymentProtectionHeaders.call(void 0, ),
|
|
762
766
|
Authorization: `Bearer ${apiKey}`,
|
|
763
767
|
"Content-Type": "application/json",
|
|
764
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
768
|
+
"User-Agent": `deepline-ts-sdk/${_chunkE5FNJE3Yjs.SDK_VERSION}`,
|
|
765
769
|
"X-Deepline-Client-Family": "sdk",
|
|
766
770
|
"X-Deepline-CLI-Family": "sdk",
|
|
767
|
-
"X-Deepline-Agent-Runtime":
|
|
768
|
-
"X-Deepline-CLI-Version":
|
|
769
|
-
"X-Deepline-SDK-Version":
|
|
771
|
+
"X-Deepline-Agent-Runtime": _chunkE5FNJE3Yjs.detectAgentRuntime.call(void 0, ),
|
|
772
|
+
"X-Deepline-CLI-Version": _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
773
|
+
"X-Deepline-SDK-Version": _chunkE5FNJE3Yjs.SDK_VERSION
|
|
770
774
|
};
|
|
771
775
|
}
|
|
772
776
|
async function postFailureReport(input) {
|
|
@@ -794,7 +798,7 @@ async function maybeReportAutomaticSkillsSyncFailure(input) {
|
|
|
794
798
|
if (isFailureReportingDisabled()) return false;
|
|
795
799
|
let apiKey = "";
|
|
796
800
|
try {
|
|
797
|
-
apiKey =
|
|
801
|
+
apiKey = _chunkE5FNJE3Yjs.resolveApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
798
802
|
} catch (e9) {
|
|
799
803
|
return false;
|
|
800
804
|
}
|
|
@@ -821,7 +825,7 @@ async function maybeReportAutomaticSkillsSyncFailure(input) {
|
|
|
821
825
|
failure_code: failureCode2,
|
|
822
826
|
failure_stage: failureStage,
|
|
823
827
|
error_body: "Automatic Deepline skills installation failed.",
|
|
824
|
-
cli_version:
|
|
828
|
+
cli_version: _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
825
829
|
context: {
|
|
826
830
|
environment: buildEnvironmentContext(),
|
|
827
831
|
skills_sync: {
|
|
@@ -941,7 +945,7 @@ function buildFailureReport(input) {
|
|
|
941
945
|
failure_kind: failureKind,
|
|
942
946
|
failure_code: code,
|
|
943
947
|
failure_stage: input.error === void 0 ? "command_exit" : "cli_main",
|
|
944
|
-
cli_version:
|
|
948
|
+
cli_version: _chunkE5FNJE3Yjs.SDK_VERSION,
|
|
945
949
|
context: {
|
|
946
950
|
base_url: redactFailureText(input.baseUrl, 400),
|
|
947
951
|
command_summary: sanitizeCommand(input.argv),
|
|
@@ -961,8 +965,8 @@ async function maybeReportSdkCliFailure(input) {
|
|
|
961
965
|
if (isServerLoggedPlayRunStartFailure(input)) return false;
|
|
962
966
|
const exitCode = resolvedExitCode(input);
|
|
963
967
|
if (!shouldReport({ exitCode, error: input.error })) return false;
|
|
964
|
-
const baseUrl =
|
|
965
|
-
const apiKey =
|
|
968
|
+
const baseUrl = _chunkE5FNJE3Yjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
969
|
+
const apiKey = _chunkE5FNJE3Yjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
966
970
|
if (!apiKey) return false;
|
|
967
971
|
return postFailureReport({
|
|
968
972
|
baseUrl,
|
|
@@ -999,25 +1003,25 @@ var CHECK_TIMEOUT_MS2 = 3e3;
|
|
|
999
1003
|
var INSTALLER_PROBE_TIMEOUT_MS = 1e3;
|
|
1000
1004
|
var PUBLISHED_VERIFICATION_RETRY_MS = 5 * 6e4;
|
|
1001
1005
|
function shouldSkipSkillsSync() {
|
|
1002
|
-
if (
|
|
1006
|
+
if (_chunkE5FNJE3Yjs.detectAgentRuntime.call(void 0, ) === "claude_cowork" || isCiEnvironment()) {
|
|
1003
1007
|
return true;
|
|
1004
1008
|
}
|
|
1005
1009
|
const value = _optionalChain([process, 'access', _84 => _84.env, 'access', _85 => _85.DEEPLINE_SKIP_SKILLS_SYNC, 'optionalAccess', _86 => _86.trim, 'call', _87 => _87(), 'access', _88 => _88.toLowerCase, 'call', _89 => _89()]);
|
|
1006
1010
|
return value === "1" || value === "true" || value === "yes" || value === "on";
|
|
1007
1011
|
}
|
|
1008
1012
|
function unavailableSkillsNoticePath(baseUrl) {
|
|
1009
|
-
return _path.join.call(void 0,
|
|
1013
|
+
return _path.join.call(void 0, _chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl), "skills-sync-unavailable-version");
|
|
1010
1014
|
}
|
|
1011
1015
|
var SKILLS_SYNC_IN_PROGRESS_TTL_MS = 10 * 60 * 1e3;
|
|
1012
1016
|
var SKILLS_SYNC_IN_PROGRESS_PID_CAP_MS = 6 * 60 * 60 * 1e3;
|
|
1013
|
-
var agentLeaseSegment =
|
|
1017
|
+
var agentLeaseSegment = _chunkE5FNJE3Yjs.skillsAgentPathSegment;
|
|
1014
1018
|
function sortedLeaseAgents(agents) {
|
|
1015
|
-
const expanded = agents.includes("*") ? [...agents, ...
|
|
1019
|
+
const expanded = agents.includes("*") ? [...agents, ..._chunkE5FNJE3Yjs.KNOWN_SKILL_AGENTS] : agents;
|
|
1016
1020
|
return [...new Set(expanded)].sort((a, b) => a.localeCompare(b));
|
|
1017
1021
|
}
|
|
1018
1022
|
function inProgressSkillsSyncPath(baseUrl, agent) {
|
|
1019
1023
|
return _path.join.call(void 0,
|
|
1020
|
-
|
|
1024
|
+
_chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
1021
1025
|
`skills-sync-in-progress-${agentLeaseSegment(agent)}`
|
|
1022
1026
|
);
|
|
1023
1027
|
}
|
|
@@ -1176,7 +1180,7 @@ var SkillsStateUnavailableError = class extends Error {
|
|
|
1176
1180
|
constructor(baseUrl, error) {
|
|
1177
1181
|
const detail = error instanceof Error ? error.message : String(error);
|
|
1178
1182
|
super(
|
|
1179
|
-
`Could not save skills state in ${
|
|
1183
|
+
`Could not save skills state in ${_chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl)}: ${detail}`
|
|
1180
1184
|
);
|
|
1181
1185
|
this.name = "SkillsStateUnavailableError";
|
|
1182
1186
|
}
|
|
@@ -1261,7 +1265,7 @@ function skillsInstallLeasePath(baseUrl, agents) {
|
|
|
1261
1265
|
}
|
|
1262
1266
|
function deferredSkillsNoticePath(baseUrl, agents) {
|
|
1263
1267
|
return _path.join.call(void 0,
|
|
1264
|
-
|
|
1268
|
+
_chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
1265
1269
|
`skills-sync-notice-${sortedLeaseAgents(agents).map(agentLeaseSegment).join("-")}`
|
|
1266
1270
|
);
|
|
1267
1271
|
}
|
|
@@ -1295,8 +1299,8 @@ function flushDeferredSkillsNotices(baseUrl, agents) {
|
|
|
1295
1299
|
if (text.trim()) writeSdkSkillsStatusLine(text.trimEnd());
|
|
1296
1300
|
}
|
|
1297
1301
|
function flushDeferredSkillsSyncNotices(baseUrl) {
|
|
1298
|
-
if (shouldSkipSkillsSync() ||
|
|
1299
|
-
const agents =
|
|
1302
|
+
if (shouldSkipSkillsSync() || _chunkE5FNJE3Yjs.hasActivePluginSkills.call(void 0, )) return;
|
|
1303
|
+
const agents = _chunkE5FNJE3Yjs.resolveAutoSyncSkillAgents.call(void 0, );
|
|
1300
1304
|
if (agents.length === 0) return;
|
|
1301
1305
|
flushDeferredSkillsNotices(baseUrl, agents);
|
|
1302
1306
|
}
|
|
@@ -1312,7 +1316,7 @@ function spawnDetachedSkillsSyncChild(argv, onSpawnError) {
|
|
|
1312
1316
|
}
|
|
1313
1317
|
function failedSkillsSyncPath(baseUrl, agents) {
|
|
1314
1318
|
return _path.join.call(void 0,
|
|
1315
|
-
|
|
1319
|
+
_chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
1316
1320
|
`skills-sync-failed-${sortedLeaseAgents(agents).map(agentLeaseSegment).join("-")}-version`
|
|
1317
1321
|
);
|
|
1318
1322
|
}
|
|
@@ -1341,7 +1345,7 @@ function writeUnavailableSkillsNotice(baseUrl, remoteVersion, skillNames, reason
|
|
|
1341
1345
|
if (hasMarkedSkillsSyncVersion(path, remoteVersion)) return;
|
|
1342
1346
|
writeMarkedSkillsSyncVersion(path, remoteVersion);
|
|
1343
1347
|
const probes = reason === "no-installer" ? _nullishCoalesce(knownProbes, () => ( probeInstallers())) : null;
|
|
1344
|
-
const manualCommand = _optionalChain([probes, 'optionalAccess', _93 => _93.npx]) === "missing" && probes.bunx !== "missing" ? `bunx ${buildBunxSkillsInstallArgs(baseUrl, skillNames,
|
|
1348
|
+
const manualCommand = _optionalChain([probes, 'optionalAccess', _93 => _93.npx]) === "missing" && probes.bunx !== "missing" ? `bunx ${buildBunxSkillsInstallArgs(baseUrl, skillNames, _chunkE5FNJE3Yjs.DEFAULT_SKILL_AGENTS).map(shellQuote).join(" ")}` : `npx ${buildSkillsInstallArgs(baseUrl, skillNames).join(" ")}`;
|
|
1345
1349
|
const explanation = reason === "unsupported-agent" ? "the detected agent has no automatic skills sync target. Automatic sync was skipped." : _optionalChain([probes, 'optionalAccess', _94 => _94.bunx]) === "missing" && probes.npx === "missing" ? "neither `bunx` nor `npx` was found on PATH. Make one available." : `installer version check failed for ${Object.entries(_nullishCoalesce(probes, () => ( {}))).filter(([, result]) => result === "failed").map(([command]) => `\`${command}\``).join(" and ")}. Check those commands with --version.`;
|
|
1346
1350
|
notice(
|
|
1347
1351
|
`Deepline agent skills are out of date, but ${explanation} To install manually, run:
|
|
@@ -1429,7 +1433,7 @@ function buildSdkSkillNames(v1SkillNames2) {
|
|
|
1429
1433
|
return sortedUniqueSkillNames(v1SkillNames2);
|
|
1430
1434
|
}
|
|
1431
1435
|
function isDefaultAgentSet(agents) {
|
|
1432
|
-
return agents.length ===
|
|
1436
|
+
return agents.length === _chunkE5FNJE3Yjs.DEFAULT_SKILL_AGENTS.length && agents.every((agent, index) => agent === _chunkE5FNJE3Yjs.DEFAULT_SKILL_AGENTS[index]);
|
|
1433
1437
|
}
|
|
1434
1438
|
function safeSkillFilePath(value) {
|
|
1435
1439
|
if (typeof value !== "string" || !value) return false;
|
|
@@ -1586,10 +1590,10 @@ async function fetchSkillsUpdate(baseUrl, localVersion) {
|
|
|
1586
1590
|
method: "POST",
|
|
1587
1591
|
headers: { "Content-Type": "application/json" },
|
|
1588
1592
|
body: JSON.stringify({
|
|
1589
|
-
sdk_cli: { version:
|
|
1593
|
+
sdk_cli: { version: _chunkE5FNJE3Yjs.SDK_VERSION },
|
|
1590
1594
|
skills: {
|
|
1591
1595
|
version: localVersion,
|
|
1592
|
-
capability:
|
|
1596
|
+
capability: _chunkF5KJFBDAjs.SDK_RELEASE.packageCapabilities.skillsGuidance
|
|
1593
1597
|
}
|
|
1594
1598
|
}),
|
|
1595
1599
|
signal: controller.signal
|
|
@@ -1628,7 +1632,7 @@ function probeInstallers(timeoutMs) {
|
|
|
1628
1632
|
}
|
|
1629
1633
|
function noInstallerProbePath(baseUrl) {
|
|
1630
1634
|
return _path.join.call(void 0,
|
|
1631
|
-
|
|
1635
|
+
_chunkE5FNJE3Yjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
1632
1636
|
"skills-sync-no-installer-unknown.json"
|
|
1633
1637
|
);
|
|
1634
1638
|
}
|
|
@@ -1707,7 +1711,7 @@ function temporarySkillsSyncSkipCommand() {
|
|
|
1707
1711
|
function resolveSkillsInstallSpawn(install, platform2 = process.platform) {
|
|
1708
1712
|
return resolveShellSpawn(install.command, install.args, platform2);
|
|
1709
1713
|
}
|
|
1710
|
-
function resolveSkillsInstallCommands(baseUrl, skillNames = DEFAULT_SDK_SKILL_NAMES, agents =
|
|
1714
|
+
function resolveSkillsInstallCommands(baseUrl, skillNames = DEFAULT_SDK_SKILL_NAMES, agents = _chunkE5FNJE3Yjs.DEFAULT_SKILL_AGENTS, knownProbes) {
|
|
1711
1715
|
const commands = [];
|
|
1712
1716
|
const probes = _nullishCoalesce(knownProbes, () => ( probeInstallers()));
|
|
1713
1717
|
if (probes.bunx === "available") {
|
|
@@ -1859,11 +1863,11 @@ function writeSdkSkillsStatusLine(line) {
|
|
|
1859
1863
|
}
|
|
1860
1864
|
async function syncSdkSkillsIfNeeded(baseUrl, options = {}) {
|
|
1861
1865
|
if (shouldSkipSkillsSync()) return;
|
|
1862
|
-
const usingPluginSkills =
|
|
1866
|
+
const usingPluginSkills = _chunkE5FNJE3Yjs.hasActivePluginSkills.call(void 0, );
|
|
1863
1867
|
if (usingPluginSkills) {
|
|
1864
1868
|
return;
|
|
1865
1869
|
}
|
|
1866
|
-
const agents =
|
|
1870
|
+
const agents = _chunkE5FNJE3Yjs.resolveAutoSyncSkillAgents.call(void 0, );
|
|
1867
1871
|
if (options.mode === "detached" && agents.length > 0) {
|
|
1868
1872
|
flushDeferredSkillsNotices(baseUrl, agents);
|
|
1869
1873
|
}
|
|
@@ -1891,7 +1895,7 @@ async function syncSdkSkillsIfNeeded(baseUrl, options = {}) {
|
|
|
1891
1895
|
return;
|
|
1892
1896
|
}
|
|
1893
1897
|
try {
|
|
1894
|
-
const localVersion =
|
|
1898
|
+
const localVersion = _chunkE5FNJE3Yjs.readSdkSkillsLocalVersion.call(void 0, baseUrl);
|
|
1895
1899
|
const update = options.update === void 0 ? claimedVersion ? { needsUpdate: true, remoteVersion: claimedVersion } : await fetchSkillsUpdate(baseUrl, localVersion) : options.update ? {
|
|
1896
1900
|
needsUpdate: options.update.needs_update,
|
|
1897
1901
|
remoteVersion: options.update.remote.version
|
|
@@ -2057,7 +2061,7 @@ async function runInlineSkillsSync(baseUrl, remoteVersion, agents, notices) {
|
|
|
2057
2061
|
}
|
|
2058
2062
|
}
|
|
2059
2063
|
runLegacySkillsCleanup(agents);
|
|
2060
|
-
if (!
|
|
2064
|
+
if (!_chunkE5FNJE3Yjs.writeSdkSkillsLocalVersion.call(void 0, baseUrl, update.remoteVersion, agents)) {
|
|
2061
2065
|
notice(
|
|
2062
2066
|
"Deepline agent skills installed, but the local skills version could not be recorded. A later command will retry the refresh."
|
|
2063
2067
|
);
|
|
@@ -4,12 +4,12 @@ import {
|
|
|
4
4
|
printCommandEnvelope,
|
|
5
5
|
printJson,
|
|
6
6
|
readCsvRows
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-NPFMAFUC.mjs";
|
|
8
|
+
import "./chunk-2MQJODFQ.mjs";
|
|
9
9
|
import "./chunk-MAMVGOSC.mjs";
|
|
10
10
|
import "./chunk-DLIRSHV6.mjs";
|
|
11
11
|
import "./chunk-E4IXDAZI.mjs";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-G3WJWD4R.mjs";
|
|
13
13
|
import "./chunk-WZYKRD7T.mjs";
|
|
14
14
|
import "./chunk-KRD6H754.mjs";
|
|
15
15
|
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
8
|
-
require('./chunk-
|
|
7
|
+
var _chunkUJTWIOQKjs = require('./chunk-UJTWIOQK.js');
|
|
8
|
+
require('./chunk-E5FNJE3Y.js');
|
|
9
9
|
require('./chunk-NPBJI7RE.js');
|
|
10
10
|
require('./chunk-XNYIZMNQ.js');
|
|
11
11
|
require('./chunk-PPDBRJRW.js');
|
|
12
|
-
require('./chunk-
|
|
12
|
+
require('./chunk-F5KJFBDA.js');
|
|
13
13
|
require('./chunk-OG64RBAC.js');
|
|
14
14
|
require('./chunk-COGTRVWW.js');
|
|
15
15
|
|
|
@@ -127,7 +127,7 @@ function renderTable(rows, totalRows, verbose, footer = `showing ${rows.length}
|
|
|
127
127
|
column.length,
|
|
128
128
|
...rows.map((row) => {
|
|
129
129
|
const value = _nullishCoalesce(row[column], () => ( ""));
|
|
130
|
-
return (verbose ? value :
|
|
130
|
+
return (verbose ? value : _chunkUJTWIOQKjs.clip.call(void 0, value, 42)).length;
|
|
131
131
|
})
|
|
132
132
|
)
|
|
133
133
|
])
|
|
@@ -137,7 +137,7 @@ function renderTable(rows, totalRows, verbose, footer = `showing ${rows.length}
|
|
|
137
137
|
const body = rows.map(
|
|
138
138
|
(row) => columns.map((column) => {
|
|
139
139
|
const raw = _nullishCoalesce(row[column], () => ( ""));
|
|
140
|
-
const display = verbose ? raw :
|
|
140
|
+
const display = verbose ? raw : _chunkUJTWIOQKjs.clip.call(void 0, raw, 42);
|
|
141
141
|
return display.padEnd(widths[column]);
|
|
142
142
|
}).join(" | ")
|
|
143
143
|
);
|
|
@@ -157,7 +157,7 @@ async function handleCsvShow(path, options, command) {
|
|
|
157
157
|
{ exitCode: 2 }
|
|
158
158
|
);
|
|
159
159
|
}
|
|
160
|
-
const allRows =
|
|
160
|
+
const allRows = _chunkUJTWIOQKjs.readCsvRows.call(void 0, csvPath);
|
|
161
161
|
const [rowStart, rowEnd] = parseRowRange(options.rows);
|
|
162
162
|
const rows = options.summary && options.rows === void 0 ? allRows : selectRows(allRows, rowStart, rowEnd);
|
|
163
163
|
const { rows: selected, columns } = selectColumns(
|
|
@@ -170,7 +170,7 @@ async function handleCsvShow(path, options, command) {
|
|
|
170
170
|
if (options.summary) {
|
|
171
171
|
const summaries = summarizeColumns(selected, columns);
|
|
172
172
|
if (format === "json") {
|
|
173
|
-
|
|
173
|
+
_chunkUJTWIOQKjs.printJson.call(void 0, {
|
|
174
174
|
rows: summaries,
|
|
175
175
|
total_rows: selected.length,
|
|
176
176
|
source_total_rows: allRows.length
|
|
@@ -179,7 +179,7 @@ async function handleCsvShow(path, options, command) {
|
|
|
179
179
|
}
|
|
180
180
|
const displayRows = summaryDisplayRows(summaries);
|
|
181
181
|
if (format === "csv") {
|
|
182
|
-
process.stdout.write(
|
|
182
|
+
process.stdout.write(_chunkUJTWIOQKjs.csvStringFromRows.call(void 0, displayRows));
|
|
183
183
|
return;
|
|
184
184
|
}
|
|
185
185
|
process.stdout.write(
|
|
@@ -194,7 +194,7 @@ async function handleCsvShow(path, options, command) {
|
|
|
194
194
|
return;
|
|
195
195
|
}
|
|
196
196
|
if (format === "json") {
|
|
197
|
-
|
|
197
|
+
_chunkUJTWIOQKjs.printJson.call(void 0, {
|
|
198
198
|
rows: selected.map((row, index) => ({ __row: rowStart + index, ...row }))
|
|
199
199
|
});
|
|
200
200
|
return;
|
|
@@ -437,7 +437,7 @@ async function handleCsvRenderStart(options) {
|
|
|
437
437
|
if (log) {
|
|
438
438
|
detail = `
|
|
439
439
|
CSV render log:
|
|
440
|
-
${
|
|
440
|
+
${_chunkUJTWIOQKjs.clip.call(void 0, log, 2e3)}`;
|
|
441
441
|
}
|
|
442
442
|
} catch (e7) {
|
|
443
443
|
}
|
|
@@ -488,7 +488,7 @@ async function handleCsvRenderStatus(options) {
|
|
|
488
488
|
if (payload.pid) lines.push(`Render PID: ${payload.pid}`);
|
|
489
489
|
if (payload.url) lines.push(`Render URL: ${payload.url}`);
|
|
490
490
|
lines.push(`Render Health: ${payload.health_status}`);
|
|
491
|
-
|
|
491
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0, payload, {
|
|
492
492
|
json: options.json,
|
|
493
493
|
text: `${lines.join("\n")}
|
|
494
494
|
`
|
|
@@ -524,7 +524,7 @@ async function handleCsvRenderStop(options) {
|
|
|
524
524
|
};
|
|
525
525
|
const text = stopped.length > 0 ? `Stopped CSV render process(es): ${stopped.join(" ")}
|
|
526
526
|
` : "No running CSV render process found.\n";
|
|
527
|
-
|
|
527
|
+
_chunkUJTWIOQKjs.printCommandEnvelope.call(void 0, payload, { json: options.json, text });
|
|
528
528
|
}
|
|
529
529
|
async function handleCsvRender(action, options) {
|
|
530
530
|
const normalized = _nullishCoalesce(action, () => ( "start"));
|