easy-soft-develop 2.1.163 → 2.1.169
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "easy-soft-develop",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.169",
|
|
4
4
|
"description": "",
|
|
5
5
|
"homepage": "https://github.com/kityandhero/easy-soft-develop#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -85,7 +85,7 @@
|
|
|
85
85
|
"terminal-kit": "^3.1.1"
|
|
86
86
|
},
|
|
87
87
|
"devDependencies": {
|
|
88
|
-
"@changesets/cli": "^2.27.
|
|
88
|
+
"@changesets/cli": "^2.27.3",
|
|
89
89
|
"@commitlint/cli": "^19.3.0",
|
|
90
90
|
"@commitlint/config-conventional": "^19.2.2",
|
|
91
91
|
"@commitlint/config-pnpm-scopes": "^19.1.0",
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
"eslint-plugin-prettier": "^5.1.3",
|
|
102
102
|
"eslint-plugin-promise": "^6.1.1",
|
|
103
103
|
"husky": "^9.0.11",
|
|
104
|
-
"lint-staged": "^15.2.
|
|
104
|
+
"lint-staged": "^15.2.5",
|
|
105
105
|
"npm-check-updates": "^16.14.20",
|
|
106
106
|
"prettier": "^3.2.5",
|
|
107
107
|
"prettier-plugin-packagejson": "^2.5.0"
|
package/src/tools/createCode.js
CHANGED
package/src/tools/meta.js
CHANGED
|
@@ -109,25 +109,141 @@ function promptEmptyLine() {
|
|
|
109
109
|
console.log('');
|
|
110
110
|
}
|
|
111
111
|
|
|
112
|
-
function promptSuccess(message) {
|
|
112
|
+
function promptSuccess(message, emptyLine = true) {
|
|
113
113
|
term.green(`${message}\r\n`);
|
|
114
|
-
|
|
114
|
+
|
|
115
|
+
if (emptyLine) {
|
|
116
|
+
promptEmptyLine();
|
|
117
|
+
}
|
|
115
118
|
}
|
|
116
119
|
|
|
117
|
-
function
|
|
120
|
+
function promptTip(title, message, emptyLine = true) {
|
|
121
|
+
term.red(`${title}: `).white(message);
|
|
122
|
+
|
|
123
|
+
if (emptyLine) {
|
|
124
|
+
promptEmptyLine();
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
function promptWarn(message, emptyLine = true) {
|
|
118
129
|
term.magenta(`${message}\r\n`);
|
|
119
|
-
|
|
130
|
+
|
|
131
|
+
if (emptyLine) {
|
|
132
|
+
promptEmptyLine();
|
|
133
|
+
}
|
|
120
134
|
}
|
|
121
135
|
|
|
122
|
-
function promptInfo(message) {
|
|
136
|
+
function promptInfo(message, emptyLine = true) {
|
|
123
137
|
term.white(`${message}\r\n`);
|
|
124
|
-
|
|
138
|
+
|
|
139
|
+
if (emptyLine) {
|
|
140
|
+
promptEmptyLine();
|
|
141
|
+
}
|
|
125
142
|
}
|
|
126
143
|
|
|
127
|
-
function promptError(error) {
|
|
144
|
+
function promptError(error, emptyLine = true) {
|
|
128
145
|
console.error(error);
|
|
129
146
|
|
|
130
|
-
|
|
147
|
+
if (emptyLine) {
|
|
148
|
+
promptEmptyLine();
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
function promptMessage(message, config, emptyLine = true) {
|
|
153
|
+
let o = term;
|
|
154
|
+
|
|
155
|
+
const { bold, dim, italic, underline, blink, inverse, strike } = {
|
|
156
|
+
bold: false,
|
|
157
|
+
dim: false,
|
|
158
|
+
italic: false,
|
|
159
|
+
underline: false,
|
|
160
|
+
blink: false,
|
|
161
|
+
inverse: false,
|
|
162
|
+
strike: false,
|
|
163
|
+
...config,
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
if (bold) {
|
|
167
|
+
o = o.bold;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
if (dim) {
|
|
171
|
+
o = o.dim;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
if (italic) {
|
|
175
|
+
o = o.italic;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
if (underline) {
|
|
179
|
+
o = o.underline;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
if (blink) {
|
|
183
|
+
o = o.blink;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
if (inverse) {
|
|
187
|
+
o = o.inverse;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
if (strike) {
|
|
191
|
+
o = o.strike;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
o(`${message}\r\n`);
|
|
195
|
+
|
|
196
|
+
if (emptyLine) {
|
|
197
|
+
promptEmptyLine();
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
function promptBlack(message, emptyLine = true) {
|
|
202
|
+
term.black(`${message}\r\n`);
|
|
203
|
+
|
|
204
|
+
if (emptyLine) {
|
|
205
|
+
promptEmptyLine();
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
function promptBackgroundBlack(message, emptyLine = true) {
|
|
210
|
+
term.bgBlack(`${message}\r\n`);
|
|
211
|
+
|
|
212
|
+
if (emptyLine) {
|
|
213
|
+
promptEmptyLine();
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
function promptRed(message, emptyLine = true) {
|
|
218
|
+
term.red(`${message}\r\n`);
|
|
219
|
+
|
|
220
|
+
if (emptyLine) {
|
|
221
|
+
promptEmptyLine();
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
function promptBackgroundRed(message, emptyLine = true) {
|
|
226
|
+
term.bgRed(`${message}\r\n`);
|
|
227
|
+
|
|
228
|
+
if (emptyLine) {
|
|
229
|
+
promptEmptyLine();
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
function promptGreen(message, emptyLine = true) {
|
|
234
|
+
term.green(`${message}\r\n`);
|
|
235
|
+
|
|
236
|
+
if (emptyLine) {
|
|
237
|
+
promptEmptyLine();
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
function promptBackgroundGreen(message, emptyLine = true) {
|
|
242
|
+
term.bgGreen(`${message}\r\n`);
|
|
243
|
+
|
|
244
|
+
if (emptyLine) {
|
|
245
|
+
promptEmptyLine();
|
|
246
|
+
}
|
|
131
247
|
}
|
|
132
248
|
|
|
133
249
|
function existPathSync(path) {
|
|
@@ -310,6 +426,7 @@ module.exports = {
|
|
|
310
426
|
promptInfo,
|
|
311
427
|
promptWarn,
|
|
312
428
|
promptError,
|
|
429
|
+
promptTip,
|
|
313
430
|
isObject,
|
|
314
431
|
isArray,
|
|
315
432
|
assignObject,
|
|
@@ -321,4 +438,11 @@ module.exports = {
|
|
|
321
438
|
resolvePath,
|
|
322
439
|
exit,
|
|
323
440
|
rimraf,
|
|
441
|
+
promptBlack,
|
|
442
|
+
promptBackgroundBlack,
|
|
443
|
+
promptRed,
|
|
444
|
+
promptBackgroundRed,
|
|
445
|
+
promptGreen,
|
|
446
|
+
promptBackgroundGreen,
|
|
447
|
+
promptMessage,
|
|
324
448
|
};
|
|
@@ -112,7 +112,7 @@ function handlePackage(projectPath, zipPath) {
|
|
|
112
112
|
copyFile({
|
|
113
113
|
sourceMainPath,
|
|
114
114
|
targetMainPath,
|
|
115
|
-
filepath: 'generatorConfig/
|
|
115
|
+
filepath: 'generatorConfig/general/',
|
|
116
116
|
callback: () => {
|
|
117
117
|
copyFile({
|
|
118
118
|
sourceMainPath,
|
package/types/tools/meta.d.ts
CHANGED
|
@@ -23,10 +23,11 @@ export function checkStringIsEmpty(v: any): boolean;
|
|
|
23
23
|
*/
|
|
24
24
|
export function promptLine(): void;
|
|
25
25
|
export function promptEmptyLine(): void;
|
|
26
|
-
export function promptSuccess(message: any): void;
|
|
27
|
-
export function promptInfo(message: any): void;
|
|
28
|
-
export function promptWarn(message: any): void;
|
|
29
|
-
export function promptError(error: any): void;
|
|
26
|
+
export function promptSuccess(message: any, emptyLine?: boolean): void;
|
|
27
|
+
export function promptInfo(message: any, emptyLine?: boolean): void;
|
|
28
|
+
export function promptWarn(message: any, emptyLine?: boolean): void;
|
|
29
|
+
export function promptError(error: any, emptyLine?: boolean): void;
|
|
30
|
+
export function promptTip(title: any, message: any, emptyLine?: boolean): void;
|
|
30
31
|
export function isObject(value: any): boolean;
|
|
31
32
|
export function isArray(value: any): boolean;
|
|
32
33
|
export function assignObject(source: any, ...mergeData: any[]): any;
|
|
@@ -62,3 +63,14 @@ export function writeFileWithOptionsSync({
|
|
|
62
63
|
export function resolvePath(path: any): any;
|
|
63
64
|
export function exit(): any;
|
|
64
65
|
export function rimraf(path: any): void;
|
|
66
|
+
export function promptBlack(message: any, emptyLine?: boolean): void;
|
|
67
|
+
export function promptBackgroundBlack(message: any, emptyLine?: boolean): void;
|
|
68
|
+
export function promptRed(message: any, emptyLine?: boolean): void;
|
|
69
|
+
export function promptBackgroundRed(message: any, emptyLine?: boolean): void;
|
|
70
|
+
export function promptGreen(message: any, emptyLine?: boolean): void;
|
|
71
|
+
export function promptBackgroundGreen(message: any, emptyLine?: boolean): void;
|
|
72
|
+
export function promptMessage(
|
|
73
|
+
message: any,
|
|
74
|
+
config: any,
|
|
75
|
+
emptyLine?: boolean,
|
|
76
|
+
): void;
|