@kscs-inc/cli 0.3.4 → 0.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/bin/kscs.mjs +18 -15
- package/package.json +1 -1
- package/release.json +25 -25
- package/release.signature.json +1 -1
package/README.md
CHANGED
|
@@ -5,15 +5,15 @@
|
|
|
5
5
|
## 安装
|
|
6
6
|
|
|
7
7
|
```sh
|
|
8
|
-
npx @kscs-inc/cli@0.3.
|
|
8
|
+
npx @kscs-inc/cli@0.3.6 install
|
|
9
9
|
# 国内镜像(同步可能延迟)
|
|
10
|
-
npx --registry=https://registry.npmmirror.com @kscs-inc/cli@0.3.
|
|
10
|
+
npx --registry=https://registry.npmmirror.com @kscs-inc/cli@0.3.6 install
|
|
11
11
|
# 或全局安装入口后显式安装客户端
|
|
12
|
-
npm install -g @kscs-inc/cli@0.3.
|
|
12
|
+
npm install -g @kscs-inc/cli@0.3.6
|
|
13
13
|
kscs install
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
旧kscs命令可能优先于npm入口,首次推荐npx;使用官网指引核对实际路径,不使用sudo覆盖。安装默认个人模式,团队用 --mode team --config /既有私有目录/team.json
|
|
16
|
+
旧kscs命令可能优先于npm入口,首次推荐npx;使用官网指引核对实际路径,不使用sudo覆盖。安装默认个人模式,团队用 --mode team --config /既有私有目录/team.json;不得把秘密写在命令中。默认按当前模式、系统和架构选择包:正式优先,没有正式目标时使用已签名映射中的试用目标并明确提示;试用不自动升级。可用 --channel stable 或 --channel trial 严格指定通道,缺目标时报错;网络、签名或摘要错误不会切换通道。
|
|
17
17
|
|
|
18
18
|
## 验证与使用
|
|
19
19
|
|
|
@@ -27,6 +27,6 @@ kscs products list
|
|
|
27
27
|
|
|
28
28
|
## 安全与更新
|
|
29
29
|
|
|
30
|
-
入口版本0.3.
|
|
30
|
+
入口版本0.3.6固定对应发行目标,验证Ed25519签名及SHA256后调用同一安装事务。客户端自带Node,后续使用kscs update check/status/apply;npm仅更新入口。npm uninstall -g @kscs-inc/cli只删除npm入口,不删除实际客户端、配置和Skill。业务请求直接到公司CLI服务,不经过npm或镜像。
|
|
31
31
|
|
|
32
32
|
如安装中断,保留原客户端与身份,按中文错误提示恢复;不关闭TLS或签名校验。镜像不可用时从npm官方源重试或使用官网安装方式。内联第三方代码许可见THIRD-PARTY-NOTICES.txt。
|
package/bin/kscs.mjs
CHANGED
|
@@ -32,9 +32,9 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
32
32
|
mod
|
|
33
33
|
));
|
|
34
34
|
|
|
35
|
-
//
|
|
35
|
+
// node_modules/.pnpm/pend@1.2.0/node_modules/pend/index.js
|
|
36
36
|
var require_pend = __commonJS({
|
|
37
|
-
"
|
|
37
|
+
"node_modules/.pnpm/pend@1.2.0/node_modules/pend/index.js"(exports, module) {
|
|
38
38
|
module.exports = Pend;
|
|
39
39
|
function Pend() {
|
|
40
40
|
this.pending = 0;
|
|
@@ -87,9 +87,9 @@ var require_pend = __commonJS({
|
|
|
87
87
|
}
|
|
88
88
|
});
|
|
89
89
|
|
|
90
|
-
//
|
|
90
|
+
// node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/fd-slicer.js
|
|
91
91
|
var require_fd_slicer = __commonJS({
|
|
92
|
-
"
|
|
92
|
+
"node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/fd-slicer.js"(exports) {
|
|
93
93
|
var fs = __require("fs");
|
|
94
94
|
var util = __require("util");
|
|
95
95
|
var stream = __require("stream");
|
|
@@ -244,9 +244,9 @@ var require_fd_slicer = __commonJS({
|
|
|
244
244
|
}
|
|
245
245
|
});
|
|
246
246
|
|
|
247
|
-
//
|
|
247
|
+
// node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/crc32.js
|
|
248
248
|
var require_crc32 = __commonJS({
|
|
249
|
-
"
|
|
249
|
+
"node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/crc32.js"(exports, module) {
|
|
250
250
|
var CRC_TABLE = new Int32Array([
|
|
251
251
|
0,
|
|
252
252
|
1996959894,
|
|
@@ -516,9 +516,9 @@ var require_crc32 = __commonJS({
|
|
|
516
516
|
}
|
|
517
517
|
});
|
|
518
518
|
|
|
519
|
-
//
|
|
519
|
+
// node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/index.js
|
|
520
520
|
var require_yauzl = __commonJS({
|
|
521
|
-
"
|
|
521
|
+
"node_modules/.pnpm/yauzl@3.4.0/node_modules/yauzl/index.js"(exports) {
|
|
522
522
|
var fs = __require("fs");
|
|
523
523
|
var zlib = __require("zlib");
|
|
524
524
|
var fd_slicer = require_fd_slicer();
|
|
@@ -1849,7 +1849,7 @@ async function installFromNpm(release, argv, onFormat) {
|
|
|
1849
1849
|
args: argv,
|
|
1850
1850
|
options: {
|
|
1851
1851
|
mode: { type: "string", default: "personal" },
|
|
1852
|
-
channel: { type: "string"
|
|
1852
|
+
channel: { type: "string" },
|
|
1853
1853
|
root: { type: "string" },
|
|
1854
1854
|
config: { type: "string" },
|
|
1855
1855
|
"skill-dir": { type: "string", multiple: true },
|
|
@@ -1862,17 +1862,21 @@ async function installFromNpm(release, argv, onFormat) {
|
|
|
1862
1862
|
});
|
|
1863
1863
|
onFormat?.(values.json === true);
|
|
1864
1864
|
if (values.json && values.human) throw new Error("--json\u4E0E--human\u4E0D\u80FD\u540C\u65F6\u4F7F\u7528");
|
|
1865
|
-
if (!INSTALL_MODES.includes(values.mode) || !["stable", "trial"].includes(values.channel))
|
|
1865
|
+
if (!INSTALL_MODES.includes(values.mode) || values.channel !== void 0 && !["stable", "trial"].includes(values.channel))
|
|
1866
1866
|
throw new Error("\u5B89\u88C5\u6A21\u5F0F\u6216\u901A\u9053\u65E0\u6548");
|
|
1867
1867
|
const arch = await nativeArchitecture();
|
|
1868
1868
|
const matches = release.targets.filter(
|
|
1869
|
-
(target2) => target2.mode === values.mode && target2.platform === process.platform && target2.arch === arch
|
|
1869
|
+
(target2) => target2.mode === values.mode && target2.platform === process.platform && target2.arch === arch
|
|
1870
1870
|
);
|
|
1871
|
-
if (matches.
|
|
1871
|
+
if (new Set(matches.map((target2) => target2.channel)).size !== matches.length)
|
|
1872
|
+
throw new Error("npm\u53D1\u884C\u76EE\u6807\u91CD\u590D\uFF0C\u505C\u6B62\u5B89\u88C5");
|
|
1873
|
+
const target = values.channel ? matches.find((candidate) => candidate.channel === values.channel) : matches.find((candidate) => candidate.channel === "stable") ?? matches.find((candidate) => candidate.channel === "trial");
|
|
1874
|
+
if (!target)
|
|
1872
1875
|
throw new Error(
|
|
1873
|
-
|
|
1876
|
+
values.channel ? `\u5F53\u524D\u5E73\u53F0\u5728\u6307\u5B9A\u901A\u9053 ${values.channel} \u6CA1\u6709\u53EF\u7528\u5B89\u88C5\u76EE\u6807\uFF1B\u4E0D\u4F1A\u81EA\u52A8\u5207\u6362\u901A\u9053\u3002` : "\u5F53\u524D\u5E73\u53F0\u6CA1\u6709\u53EF\u7528\u5B89\u88C5\u76EE\u6807\uFF0C\u8BF7\u6838\u5BF9\u5B89\u88C5\u6A21\u5F0F\u3001\u7CFB\u7EDF\u67B6\u6784\u4E0Enpm\u5165\u53E3\u7248\u672C\u3002"
|
|
1874
1877
|
);
|
|
1875
|
-
|
|
1878
|
+
if (target.channel === "trial" && values["update-policy"] === "auto")
|
|
1879
|
+
throw new Error("\u8BD5\u7528\u76EE\u6807\u7981\u6B62\u81EA\u52A8\u5347\u7EA7");
|
|
1876
1880
|
if (target.channel === "trial")
|
|
1877
1881
|
process.stderr.write("\u6CE8\u610F\uFF1A\u5F53\u524D\u76EE\u6807\u4E3A\u8BD5\u7528\u901A\u9053\uFF0C\u539F\u751F\u9A8C\u6536\u672A\u5B8C\u6210\uFF0C\u4E0D\u542F\u7528\u81EA\u52A8\u5347\u7EA7\u3002\n");
|
|
1878
1882
|
const root = resolve2(values.root ?? defaultInstallRoot(target.mode));
|
|
@@ -1931,7 +1935,6 @@ async function installFromNpm(release, argv, onFormat) {
|
|
|
1931
1935
|
if (values["no-path"]) installerArguments.push("--no-path");
|
|
1932
1936
|
if (values["verify-connection"]) installerArguments.push("--verify-connection");
|
|
1933
1937
|
if (target.channel === "trial") {
|
|
1934
|
-
if (values["update-policy"] === "auto") throw new Error("\u8BD5\u7528\u76EE\u6807\u7981\u6B62\u81EA\u52A8\u5347\u7EA7");
|
|
1935
1938
|
installerArguments.push("--update-policy", "off");
|
|
1936
1939
|
}
|
|
1937
1940
|
const status = await runNpmChild(
|
package/package.json
CHANGED
package/release.json
CHANGED
|
@@ -1,79 +1,79 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema_version": 1,
|
|
3
3
|
"name": "@kscs-inc/cli",
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.6",
|
|
5
5
|
"targets": [
|
|
6
6
|
{
|
|
7
7
|
"mode": "personal",
|
|
8
8
|
"platform": "darwin",
|
|
9
9
|
"arch": "x64",
|
|
10
10
|
"channel": "stable",
|
|
11
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/
|
|
12
|
-
"manifest_sha256": "
|
|
13
|
-
"build_id": "
|
|
11
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/20261025-094324-6a216831/manifest.json",
|
|
12
|
+
"manifest_sha256": "509dc77014d55a99f037ced9e468f537c7f3e1584ce9fba0590437221fb87204",
|
|
13
|
+
"build_id": "20261025-094324-6a216831"
|
|
14
14
|
},
|
|
15
15
|
{
|
|
16
16
|
"mode": "team",
|
|
17
17
|
"platform": "linux",
|
|
18
18
|
"arch": "x64",
|
|
19
19
|
"channel": "stable",
|
|
20
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/
|
|
21
|
-
"manifest_sha256": "
|
|
22
|
-
"build_id": "
|
|
20
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/20261025-094459-bffbfb5d/manifest.json",
|
|
21
|
+
"manifest_sha256": "71412b4b44a05135b3d9911c2c5dd9d99a430b57c8d011802b39cf623fbc3552",
|
|
22
|
+
"build_id": "20261025-094459-bffbfb5d"
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
25
|
"mode": "personal",
|
|
26
26
|
"platform": "darwin",
|
|
27
27
|
"arch": "arm64",
|
|
28
28
|
"channel": "trial",
|
|
29
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
30
|
-
"manifest_sha256": "
|
|
31
|
-
"build_id": "
|
|
29
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094313-47d1ddfd/manifest.json",
|
|
30
|
+
"manifest_sha256": "6fd6d2aed977b9911e76619b06b30bde542a75a3b261e456c022c430e50b6caf",
|
|
31
|
+
"build_id": "20261025-094313-47d1ddfd"
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
34
|
"mode": "personal",
|
|
35
35
|
"platform": "linux",
|
|
36
36
|
"arch": "arm64",
|
|
37
37
|
"channel": "trial",
|
|
38
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
39
|
-
"manifest_sha256": "
|
|
40
|
-
"build_id": "
|
|
38
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094340-4e3697dd/manifest.json",
|
|
39
|
+
"manifest_sha256": "a163360a975210639ae6b44752530ddcbad88c085e5c7c1101c7f396fd696fb7",
|
|
40
|
+
"build_id": "20261025-094340-4e3697dd"
|
|
41
41
|
},
|
|
42
42
|
{
|
|
43
43
|
"mode": "personal",
|
|
44
44
|
"platform": "linux",
|
|
45
45
|
"arch": "x64",
|
|
46
46
|
"channel": "trial",
|
|
47
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
48
|
-
"manifest_sha256": "
|
|
49
|
-
"build_id": "
|
|
47
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094358-3996bdc3/manifest.json",
|
|
48
|
+
"manifest_sha256": "8e11b1749d968fcca2b0177654cb26ef07fe11a4b5dd5a8314cfce6ba33dfc7d",
|
|
49
|
+
"build_id": "20261025-094358-3996bdc3"
|
|
50
50
|
},
|
|
51
51
|
{
|
|
52
52
|
"mode": "personal",
|
|
53
53
|
"platform": "win32",
|
|
54
54
|
"arch": "arm64",
|
|
55
55
|
"channel": "trial",
|
|
56
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
57
|
-
"manifest_sha256": "
|
|
58
|
-
"build_id": "
|
|
56
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094414-cc841444/manifest.json",
|
|
57
|
+
"manifest_sha256": "d8a0388075fee005133c47c7b66ca0644280b6b27c3f4f67c1ae88917cd7e6b9",
|
|
58
|
+
"build_id": "20261025-094414-cc841444"
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
61
|
"mode": "personal",
|
|
62
62
|
"platform": "win32",
|
|
63
63
|
"arch": "x64",
|
|
64
64
|
"channel": "trial",
|
|
65
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
66
|
-
"manifest_sha256": "
|
|
67
|
-
"build_id": "
|
|
65
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094430-72e23d4c/manifest.json",
|
|
66
|
+
"manifest_sha256": "c0e4345068a4a88b05400fb015be6af4a9e0fe3cd94c664a9d8648e6703e08cc",
|
|
67
|
+
"build_id": "20261025-094430-72e23d4c"
|
|
68
68
|
},
|
|
69
69
|
{
|
|
70
70
|
"mode": "team",
|
|
71
71
|
"platform": "linux",
|
|
72
72
|
"arch": "arm64",
|
|
73
73
|
"channel": "trial",
|
|
74
|
-
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/
|
|
75
|
-
"manifest_sha256": "
|
|
76
|
-
"build_id": "
|
|
74
|
+
"manifest": "https://cli.xaweiju.com/downloads/cli/node/trial/20261025-094444-62377ef8/manifest.json",
|
|
75
|
+
"manifest_sha256": "23482fcd6de75844b428b9dd12277e4f6108b7ce6e4542f7d1c137b3f4edaf83",
|
|
76
|
+
"build_id": "20261025-094444-62377ef8"
|
|
77
77
|
}
|
|
78
78
|
]
|
|
79
79
|
}
|
package/release.signature.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"algorithm":"Ed25519","key_id":"kscs-release-20261023","payload":"
|
|
1
|
+
{"algorithm":"Ed25519","key_id":"kscs-release-20261023","payload":"eyJzY2hlbWFfdmVyc2lvbiI6MSwicGF0aCI6Ii9kb3dubG9hZHMvY2xpL25vZGUvbnBtLzAuMy42L3JlbGVhc2UuanNvbiIsInNoYTI1NiI6ImNiYWIyZmNhMDJkZDQyNTMwNDc3NTcwMGVjNGUzN2Q5MDRkMWI5ZDUxYjJiNzAwMmU4MTc5ZDE3MzIxODM1ZWUiLCJpc3N1ZWRfYXQiOjE3OTI4OTYyODIsImV4cGlyZXNfYXQiOjE4MjQ0MzIyODJ9","signature":"evM2QJoVbi5wruyK7vRNTLqMgD90QUWZLrsuAIOlcSfPmn2VJC2UgtcOeWchUHWwhF9J3EuxbQbNlBWufHL6Aw=="}
|