@infinity-cli/ipublish 1.2.4 → 1.3.1
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/command/config.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ declare const TypeBox_PublishConfig: import("@sinclair/typebox").TObject<{
|
|
|
16
16
|
cmd: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
17
17
|
cwd: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
18
18
|
}>;
|
|
19
|
-
export type Type_PublishConfig = Static<typeof TypeBox_PublishConfig>;
|
|
19
|
+
export declare type Type_PublishConfig = Static<typeof TypeBox_PublishConfig>;
|
|
20
20
|
export declare const runtimeConfig: RuntimeConfig<{
|
|
21
21
|
jumpIp?: string | undefined;
|
|
22
22
|
jumpUser?: string | undefined;
|
|
@@ -30,7 +30,7 @@ export declare const runtimeConfig: RuntimeConfig<{
|
|
|
30
30
|
cwd?: string | undefined;
|
|
31
31
|
ip: string;
|
|
32
32
|
user: string;
|
|
33
|
-
from:
|
|
33
|
+
from: import("@sinclair/typebox").StaticArray<import("@sinclair/typebox").TString>;
|
|
34
34
|
to: string;
|
|
35
35
|
}>;
|
|
36
36
|
export {};
|
package/dist/command/upload.js
CHANGED
|
@@ -47,7 +47,7 @@ const uploadRemoteWithConfig = (config) => __awaiter(void 0, void 0, void 0, fun
|
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
49
|
console.log(`开始连接并上传:${ip} ${to}`);
|
|
50
|
-
if (jumpIp) {
|
|
50
|
+
if (typeof jumpIp === 'string' && jumpIp) {
|
|
51
51
|
spinner.text = '使用跳板机连接';
|
|
52
52
|
const jumpConfig = {
|
|
53
53
|
host: jumpIp,
|
|
@@ -142,7 +142,7 @@ const uploadRemoteWithConfig = (config) => __awaiter(void 0, void 0, void 0, fun
|
|
|
142
142
|
}
|
|
143
143
|
});
|
|
144
144
|
exports.uploadRemoteWithConfig = uploadRemoteWithConfig;
|
|
145
|
-
const uploadRemoteAction = (
|
|
145
|
+
const uploadRemoteAction = (LABEL_ENV, { config: configName } = { config: undefined }, { args } = { args: undefined }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
146
146
|
const config = yield config_1.runtimeConfig.getConfig(args, configName, LABEL_ENV);
|
|
147
147
|
if (!config.password && !config.privateKey) {
|
|
148
148
|
console.error('password和privateKey至少设置一项');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@infinity-cli/ipublish",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.1",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"description": "上传服务器文件",
|
|
6
6
|
"main": "dist/lib/index.js",
|
|
@@ -27,13 +27,13 @@
|
|
|
27
27
|
"infinity-cli"
|
|
28
28
|
],
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@infinity-cli/shared": "^1.2.
|
|
31
|
-
"@sinclair/typebox": "
|
|
30
|
+
"@infinity-cli/shared": "^1.2.3",
|
|
31
|
+
"@sinclair/typebox": "0.23.5",
|
|
32
32
|
"archiver": "^5.3.0",
|
|
33
33
|
"commander": "^8.2.0",
|
|
34
34
|
"node-ssh": "^12.0.3",
|
|
35
35
|
"ora": "5",
|
|
36
36
|
"rimraf": "^3.0.2"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "a175b8097dcb5533b1a8b76d878fc4777c3785a0"
|
|
39
39
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"root":["../src/bin.ts","../src/util.ts","../src/command/config.ts","../src/command/upload.ts","../src/lib/index.ts"],"version":"5.6.2"}
|