@nocobase/cli 2.0.0-alpha.56 → 2.0.0-alpha.57
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/package.json +5 -5
- package/src/commands/pkg.js +3 -0
- package/src/license.js +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/cli",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.57",
|
|
4
4
|
"description": "",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"main": "./src/index.js",
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
"nocobase": "./bin/index.js"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@nocobase/app": "2.0.0-alpha.
|
|
12
|
-
"@nocobase/license-kit": "^0.3.
|
|
11
|
+
"@nocobase/app": "2.0.0-alpha.57",
|
|
12
|
+
"@nocobase/license-kit": "^0.3.5",
|
|
13
13
|
"@types/fs-extra": "^11.0.1",
|
|
14
14
|
"@umijs/utils": "3.5.20",
|
|
15
15
|
"chalk": "^4.1.1",
|
|
@@ -27,12 +27,12 @@
|
|
|
27
27
|
"tsx": "^4.19.0"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@nocobase/devtools": "2.0.0-alpha.
|
|
30
|
+
"@nocobase/devtools": "2.0.0-alpha.57"
|
|
31
31
|
},
|
|
32
32
|
"repository": {
|
|
33
33
|
"type": "git",
|
|
34
34
|
"url": "git+https://github.com/nocobase/nocobase.git",
|
|
35
35
|
"directory": "packages/core/cli"
|
|
36
36
|
},
|
|
37
|
-
"gitHead": "
|
|
37
|
+
"gitHead": "b9ec8bc83fd86a9cadfc4fb2f87a4e015061b289"
|
|
38
38
|
}
|
package/src/commands/pkg.js
CHANGED
|
@@ -202,6 +202,7 @@ class PackageManager {
|
|
|
202
202
|
responseType: 'json',
|
|
203
203
|
});
|
|
204
204
|
this.token = res1.data.token;
|
|
205
|
+
logger.info('Login success');
|
|
205
206
|
} catch (error) {
|
|
206
207
|
if (error?.response?.data?.error === 'license not valid') {
|
|
207
208
|
showLicenseInfo(LicenseKeyError.notValid);
|
|
@@ -260,9 +261,11 @@ class PackageManager {
|
|
|
260
261
|
await this.removePackage(pkg);
|
|
261
262
|
}
|
|
262
263
|
}
|
|
264
|
+
logger.info(`Download plugins...`);
|
|
263
265
|
for (const pkg of licensed_plugins) {
|
|
264
266
|
await this.getPackage(pkg).download({ version });
|
|
265
267
|
}
|
|
268
|
+
logger.info('Download plugins done');
|
|
266
269
|
}
|
|
267
270
|
}
|
|
268
271
|
|
package/src/license.js
CHANGED
|
@@ -18,9 +18,10 @@ const { pick } = require('lodash');
|
|
|
18
18
|
exports.getAccessKeyPair = async function () {
|
|
19
19
|
const keyFile = resolve(process.cwd(), 'storage/.license/license-key');
|
|
20
20
|
if (!fs.existsSync(keyFile)) {
|
|
21
|
+
logger.error('License key not found');
|
|
21
22
|
return {};
|
|
22
23
|
}
|
|
23
|
-
|
|
24
|
+
logger.info('License key found');
|
|
24
25
|
let keyData = {};
|
|
25
26
|
try {
|
|
26
27
|
const str = fs.readFileSync(keyFile, 'utf-8');
|