@workclaw/cli 1.0.319 → 1.0.321
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 +16 -17
- package/dist/box/installer/installer.d.ts.map +1 -1
- package/dist/box/src/box.d.ts +4 -0
- package/dist/box/src/box.d.ts.map +1 -1
- package/dist/box/types/index.d.ts +19 -10
- package/dist/box/types/index.d.ts.map +1 -1
- package/dist/{index-DU1f2pnd.js → index-DsyMquTQ.js} +294 -248
- package/dist/index.js +1 -1
- package/dist/local/apis/index.d.ts +10 -9
- package/dist/local/apis/index.d.ts.map +1 -1
- package/dist/local/installer/installer.d.ts +36 -1
- package/dist/local/installer/installer.d.ts.map +1 -1
- package/dist/local/src/local.d.ts +4 -0
- package/dist/local/src/local.d.ts.map +1 -1
- package/dist/local/types/index.d.ts +31 -18
- package/dist/local/types/index.d.ts.map +1 -1
- package/dist/local/utils/index.d.ts +2 -1
- package/dist/local/utils/index.d.ts.map +1 -1
- package/dist/local/utils/machine-id.d.ts +10 -0
- package/dist/local/utils/machine-id.d.ts.map +1 -0
- package/dist/local/utils/path.d.ts +0 -6
- package/dist/local/utils/path.d.ts.map +1 -1
- package/dist/shared/utils/debug.d.ts +11 -2
- package/dist/shared/utils/debug.d.ts.map +1 -1
- package/dist/shared/utils/env.d.ts +6 -0
- package/dist/shared/utils/env.d.ts.map +1 -0
- package/dist/shared/utils/index.d.ts +2 -1
- package/dist/shared/utils/index.d.ts.map +1 -1
- package/dist/shared/utils/path.d.ts.map +1 -1
- package/dist/shared/utils/validate.d.ts +80 -0
- package/dist/shared/utils/validate.d.ts.map +1 -1
- package/dist/utils/config.d.ts +12 -5
- package/dist/utils/config.d.ts.map +1 -1
- package/dist/utils/http.d.ts +4 -13
- package/dist/utils/http.d.ts.map +1 -1
- package/dist/utils/index.d.ts +0 -1
- package/dist/utils/index.d.ts.map +1 -1
- package/package.json +2 -1
- package/dist/utils/path.d.ts +0 -23
- package/dist/utils/path.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -100,27 +100,27 @@ npx @workclaw/cli --help
|
|
|
100
100
|
|
|
101
101
|
### local 命令参数
|
|
102
102
|
|
|
103
|
-
| 参数 | 说明
|
|
104
|
-
| ---------------- |
|
|
105
|
-
| --phone | 手机号码(登录账号),未填写时会交互式提示输入
|
|
106
|
-
| --user-pass | 用户密码,未填写时会交互式提示输入
|
|
103
|
+
| 参数 | 说明 |
|
|
104
|
+
| ---------------- | ------------------------------------------ |
|
|
105
|
+
| --phone | 手机号码(登录账号),未填写时会交互式提示输入 |
|
|
106
|
+
| --user-pass | 用户密码,未填写时会交互式提示输入 |
|
|
107
107
|
| --env | 环境 (test/prod/custom),默认 test,未填写时会交互式提示选择 |
|
|
108
|
-
| --customIp | 自定义环境后端 IP,仅当 env 为 custom 时使用
|
|
109
|
-
| --plugin-version | 插件版本号(默认安装最新版)
|
|
110
|
-
| --openclaw-path | OpenClaw 安装目录(默认 \~/.openclaw)
|
|
111
|
-
| --debug | 开启调试日志
|
|
108
|
+
| --customIp | 自定义环境后端 IP,仅当 env 为 custom 时使用 |
|
|
109
|
+
| --plugin-version | 插件版本号(默认安装最新版) |
|
|
110
|
+
| --openclaw-path | OpenClaw 安装目录(默认 \~/.openclaw) |
|
|
111
|
+
| --debug | 开启调试日志 |
|
|
112
112
|
|
|
113
113
|
### box 命令参数
|
|
114
114
|
|
|
115
|
-
| 参数 | 说明
|
|
116
|
-
| ---------------- |
|
|
117
|
-
| --app-key | App Key,未填写时会交互式提示输入
|
|
118
|
-
| --app-secret | App Secret,未填写时会交互式提示输入
|
|
115
|
+
| 参数 | 说明 |
|
|
116
|
+
| ---------------- | ------------------------------------------ |
|
|
117
|
+
| --app-key | App Key,未填写时会交互式提示输入 |
|
|
118
|
+
| --app-secret | App Secret,未填写时会交互式提示输入 |
|
|
119
119
|
| --env | 环境 (test/prod/custom),默认 test,未填写时会交互式提示选择 |
|
|
120
|
-
| --customIp | 自定义环境后端 IP,仅当 env 为 custom 时使用
|
|
121
|
-
| --plugin-version | 插件版本号(默认安装最新版)
|
|
122
|
-
| --openclaw-path | OpenClaw 安装目录(默认 \~/.openclaw)
|
|
123
|
-
| --debug | 开启调试日志
|
|
120
|
+
| --customIp | 自定义环境后端 IP,仅当 env 为 custom 时使用 |
|
|
121
|
+
| --plugin-version | 插件版本号(默认安装最新版) |
|
|
122
|
+
| --openclaw-path | OpenClaw 安装目录(默认 \~/.openclaw) |
|
|
123
|
+
| --debug | 开启调试日志 |
|
|
124
124
|
|
|
125
125
|
## 💡 使用示例
|
|
126
126
|
|
|
@@ -351,4 +351,3 @@ MIT License
|
|
|
351
351
|
- [ora](https://github.com/sindresorhus/ora) - 加载动画
|
|
352
352
|
- [axios](https://github.com/axios/axios) - HTTP 客户端
|
|
353
353
|
- [tar](https://github.com/isaacs/node-tar) - tar 文件解压
|
|
354
|
-
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"installer.d.ts","sourceRoot":"","sources":["../../../src/box/installer/installer.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"installer.d.ts","sourceRoot":"","sources":["../../../src/box/installer/installer.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAgB,MAAM,UAAU,CAAA;AAkEhE,qBAAa,YAAY;IAIX,OAAO,CAAC,MAAM;IAH1B,OAAO,CAAC,OAAO,CAAK;IACpB,OAAO,CAAC,UAAU,CAAa;gBAEX,MAAM,EAAE,kBAAkB;IAI9C,cAAc,IAAI,IAAI;IAyBtB,OAAO,CAAC,QAAQ;IAoChB,OAAO,CAAC,aAAa;IAMrB,aAAa,IAAI,MAAM;IAIvB,OAAO,CAAC,cAAc;IAOhB,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;YA0BhB,eAAe;YA0Bf,iBAAiB;YAoHjB,cAAc;CAoR7B"}
|
package/dist/box/src/box.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"box.d.ts","sourceRoot":"","sources":["../../../src/box/src/box.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;
|
|
1
|
+
{"version":3,"file":"box.d.ts","sourceRoot":"","sources":["../../../src/box/src/box.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAQ1C;;;GAGG;AACH,wBAAsB,gBAAgB,CAAC,OAAO,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CAuJzE"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { z } from 'zod';
|
|
2
2
|
export interface BoxOptions {
|
|
3
3
|
env?: string;
|
|
4
4
|
appKey?: string;
|
|
@@ -9,15 +9,24 @@ export interface BoxOptions {
|
|
|
9
9
|
openclawPath?: string;
|
|
10
10
|
debug?: boolean;
|
|
11
11
|
}
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
12
|
+
/**
|
|
13
|
+
* BoxInstaller 配置验证 schema
|
|
14
|
+
* 当 env === 'custom' 时,customIp 必填
|
|
15
|
+
*/
|
|
16
|
+
export declare const BoxInstallerConfigSchema: z.ZodObject<{
|
|
17
|
+
env: z.ZodOptional<z.ZodEnum<{
|
|
18
|
+
test: "test";
|
|
19
|
+
prod: "prod";
|
|
20
|
+
custom: "custom";
|
|
21
|
+
}>>;
|
|
22
|
+
customIp: z.ZodOptional<z.ZodIPv4>;
|
|
23
|
+
wsUrl: z.ZodOptional<z.ZodString>;
|
|
24
|
+
appKey: z.ZodString;
|
|
25
|
+
appSecret: z.ZodString;
|
|
26
|
+
pluginVersion: z.ZodOptional<z.ZodString>;
|
|
27
|
+
openclawPath: z.ZodOptional<z.ZodIntersection<z.ZodString, z.ZodString>>;
|
|
28
|
+
}, z.core.$strip>;
|
|
29
|
+
export type BoxInstallerConfig = z.infer<typeof BoxInstallerConfigSchema>;
|
|
21
30
|
export interface InstallResult {
|
|
22
31
|
success: boolean;
|
|
23
32
|
message?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/box/types/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/box/types/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAWvB,MAAM,WAAW,UAAU;IACzB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,KAAK,CAAC,EAAE,OAAO,CAAA;CAChB;AAED;;;GAGG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;iBAmBpC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAA;AAEzE,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAA;IACZ,UAAU,EAAE,MAAM,CAAA;IAClB,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,MAAM,CAAA;CACb"}
|