easy-soft-develop 2.0.177 → 2.0.179

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.0.177",
3
+ "version": "2.0.179",
4
4
  "description": "",
5
5
  "homepage": "https://github.com/kityandhero/easy-soft-develop#readme",
6
6
  "bugs": {
@@ -16,6 +16,7 @@ const {
16
16
  createBabelConfigFile,
17
17
  createNcuConfigFile,
18
18
  createNpmConfigFile,
19
+ createCzConfigFile,
19
20
  } = require('../tools/develop.file');
20
21
  const { globalScript, packageScript } = require('../tools/package.script');
21
22
  const {
@@ -234,12 +235,6 @@ function initialEnvironment() {
234
235
 
235
236
  promptEmptyLine();
236
237
 
237
- promptInfo('create git branch main');
238
-
239
- exec('git init -b main');
240
-
241
- promptEmptyLine();
242
-
243
238
  promptInfo('husky install');
244
239
 
245
240
  exec('npx husky install');
@@ -267,6 +262,7 @@ function createLernaProject(name) {
267
262
  createPackageJsonFile(name);
268
263
 
269
264
  createCommitlintConfigFile(`step *: create commitlint.config.js success`);
265
+ createCzConfigFile(`step *: create .czrc success`);
270
266
  createBabelConfigFile(`step *: create babel.config.js success`);
271
267
  createNcuConfigFile(`step *: create .ncurc.json success`);
272
268
  createNpmConfigFile(`step *: create .npmrc success`);
@@ -0,0 +1,15 @@
1
+ const folderPath = '.';
2
+
3
+ const contentFileContent = `{
4
+ "path": "@commitlint/cz-commitlint"
5
+ }
6
+ `;
7
+
8
+ const contentFile = {
9
+ folderPath: `${folderPath}`,
10
+ fileName: '.czrc',
11
+ coverFile: true,
12
+ fileContent: contentFileContent,
13
+ };
14
+
15
+ module.exports = { contentFile };
@@ -13,6 +13,9 @@ const { fileGlobalHeader } = require('../templates/template.config');
13
13
  const {
14
14
  contentFile: commitlintConfigContentFile,
15
15
  } = require('../templates/commitlint.config.template');
16
+ const {
17
+ contentFile: czConfigContentFile,
18
+ } = require('../templates/cz.config.template');
16
19
  const {
17
20
  contentFile: babelConfigContentFile,
18
21
  } = require('../templates/babel.config.template');
@@ -176,6 +179,16 @@ function createScriptFile(folderPath, fileName, content, coverFile = false) {
176
179
  return result;
177
180
  }
178
181
 
182
+ function createCzConfigFile(successMessage = '') {
183
+ let result = writeFileWithOptionsSync(czConfigContentFile);
184
+
185
+ if (result) {
186
+ if (!checkStringIsEmpty(successMessage)) {
187
+ promptInfo(successMessage);
188
+ }
189
+ }
190
+ }
191
+
179
192
  function createCommitlintConfigFile(successMessage = '') {
180
193
  let result = writeFileWithOptionsSync(commitlintConfigContentFile);
181
194
 
@@ -677,6 +690,7 @@ function createDevelopFiles(waitMessage = '', successMessage = '') {
677
690
  }
678
691
 
679
692
  module.exports = {
693
+ createCzConfigFile,
680
694
  createCommitlintConfigFile,
681
695
  createBabelConfigFile,
682
696
  createNcuConfigFile,
@@ -0,0 +1,8 @@
1
+ export namespace contentFile {
2
+ export const folderPath: string;
3
+ export const fileName: string;
4
+ export const coverFile: boolean;
5
+ export { contentFileContent as fileContent };
6
+ }
7
+ declare const contentFileContent: "{\n \"path\": \"@commitlint/cz-commitlint\"\n}\n";
8
+ export {};
@@ -1,3 +1,4 @@
1
+ export function createCzConfigFile(successMessage?: string): void;
1
2
  export function createCommitlintConfigFile(successMessage?: string): void;
2
3
  export function createBabelConfigFile(successMessage?: string): void;
3
4
  export function createNcuConfigFile(successMessage?: string): void;