@gadmin2n/cli 0.0.126 → 0.0.128
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/actions/new.action.js +7 -3
- package/package.json +2 -2
package/actions/new.action.js
CHANGED
|
@@ -80,6 +80,13 @@ class NewAction extends abstract_action_1.AbstractAction {
|
|
|
80
80
|
catch (_a) {
|
|
81
81
|
// best-effort, never fatal
|
|
82
82
|
}
|
|
83
|
+
// Run git init BEFORE yarn install so that the template's `prepare`
|
|
84
|
+
// script (`cd .. && husky install`) can find the .git directory.
|
|
85
|
+
// Without this, husky install fails → yarn exits non-zero → CLI
|
|
86
|
+
// incorrectly reports "Packages installation failed!".
|
|
87
|
+
if (!shouldSkipGit) {
|
|
88
|
+
yield initializeGitRepository(projectAbsDir);
|
|
89
|
+
}
|
|
83
90
|
}
|
|
84
91
|
if (!shouldSkipInstall) {
|
|
85
92
|
console.info('Begin to install server dependence ...');
|
|
@@ -90,9 +97,6 @@ class NewAction extends abstract_action_1.AbstractAction {
|
|
|
90
97
|
console.info();
|
|
91
98
|
}
|
|
92
99
|
if (!isDryRunEnabled) {
|
|
93
|
-
if (!shouldSkipGit) {
|
|
94
|
-
yield initializeGitRepository(projectAbsDir);
|
|
95
|
-
}
|
|
96
100
|
const inputPackageManager = (options.find((option) => option.name === 'package-manager')
|
|
97
101
|
.value || 'yarn').toLowerCase();
|
|
98
102
|
// 收集仍未填写、需要在引导中提示用户处理的环境变量
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gadmin2n/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.128",
|
|
4
4
|
"description": "Gadmin - modern, fast, powerful node.js web framework (@cli)",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"@angular-devkit/core": "13.3.2",
|
|
48
48
|
"@angular-devkit/schematics": "13.3.2",
|
|
49
49
|
"@angular-devkit/schematics-cli": "13.3.2",
|
|
50
|
-
"@gadmin2n/schematics": "^0.0.
|
|
50
|
+
"@gadmin2n/schematics": "^0.0.99",
|
|
51
51
|
"abc": "^0.6.1",
|
|
52
52
|
"chalk": "3.0.0",
|
|
53
53
|
"chokidar": "3.5.3",
|