@modern-js/packages-generator 3.3.9 → 3.3.11

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.
Files changed (2) hide show
  1. package/dist/index.js +27 -27
  2. package/package.json +9 -9
package/dist/index.js CHANGED
@@ -52667,12 +52667,12 @@ function _define_property(obj, key, value) {
52667
52667
  return obj;
52668
52668
  }
52669
52669
 
52670
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
52670
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
52671
52671
  var import_utils13 = require("@modern-js/utils");
52672
52672
  var import_lodash5 = require("@modern-js/utils/lodash");
52673
52673
  var import_comment_json = __toESM(require_src2());
52674
52674
 
52675
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.4/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/env.js
52675
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.5/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/env.js
52676
52676
  var import_utils = require("@modern-js/utils");
52677
52677
  async function canUseNvm() {
52678
52678
  try {
@@ -52722,7 +52722,7 @@ async function canUsePnpm() {
52722
52722
  }
52723
52723
  }
52724
52724
 
52725
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.4/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/install.js
52725
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.5/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/install.js
52726
52726
  var import_utils2 = require("@modern-js/utils");
52727
52727
  function execaWithStreamLog(command, args, options) {
52728
52728
  const promise = (0, import_utils2.execa)(command, args, {
@@ -52818,7 +52818,7 @@ async function pnpmInstall({ cwd, registryUrl, ignoreScripts, useNvm }) {
52818
52818
  throw new Error("please install pnpm first");
52819
52819
  }
52820
52820
 
52821
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.4/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/index.js
52821
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.3.5/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/index.js
52822
52822
  var NpmAPI = class {
52823
52823
  npmInstall({ cwd, registryUrl, ignoreScripts }) {
52824
52824
  return npmInstall({
@@ -52847,7 +52847,7 @@ var NpmAPI = class {
52847
52847
  }
52848
52848
  };
52849
52849
 
52850
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-git/dist/esm-node/utils/index.js
52850
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-git/dist/esm-node/utils/index.js
52851
52851
  var import_utils4 = require("@modern-js/utils");
52852
52852
  async function canUseGit() {
52853
52853
  try {
@@ -52922,7 +52922,7 @@ async function gitCommit(cwd, commitMessage) {
52922
52922
  });
52923
52923
  }
52924
52924
 
52925
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-git/dist/esm-node/index.js
52925
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-git/dist/esm-node/index.js
52926
52926
  var GitAPI = class {
52927
52927
  async isInGitRepo(cwd = this.generatorCore.outputPath) {
52928
52928
  const canUse = await canUseGit();
@@ -52974,12 +52974,12 @@ var GitAPI = class {
52974
52974
  }
52975
52975
  };
52976
52976
 
52977
- // ../../../../node_modules/.pnpm/@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith/dist/esm-node/materials/FsResource.js
52977
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith/dist/esm-node/materials/FsResource.js
52978
52978
  var import_path = __toESM(require("path"));
52979
52979
  var import_utils6 = require("@modern-js/utils");
52980
52980
  var FS_RESOURCE = "_codesmith_core_fs_resource";
52981
52981
 
52982
- // ../../../../node_modules/.pnpm/@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith/dist/esm-node/utils/fsExists.js
52982
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith/dist/esm-node/utils/fsExists.js
52983
52983
  var import_utils7 = require("@modern-js/utils");
52984
52984
  async function fsExists(path6) {
52985
52985
  try {
@@ -52990,7 +52990,7 @@ async function fsExists(path6) {
52990
52990
  }
52991
52991
  }
52992
52992
 
52993
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/utils/renderString.js
52993
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/utils/renderString.js
52994
52994
  var import_handlebars = __toESM(require_lib());
52995
52995
  function renderString(template, fullData, registers) {
52996
52996
  const helpers = {
@@ -53004,7 +53004,7 @@ function renderString(template, fullData, registers) {
53004
53004
  return import_handlebars.default.compile(template)(fullData) || "";
53005
53005
  }
53006
53006
 
53007
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/index.js
53007
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/index.js
53008
53008
  var HandlebarsAPI = class {
53009
53009
  async registerHelp(helpers) {
53010
53010
  this.registers.helpers = {
@@ -53054,13 +53054,13 @@ var HandlebarsAPI = class {
53054
53054
  }
53055
53055
  };
53056
53056
 
53057
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/utils/renderString.js
53057
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/utils/renderString.js
53058
53058
  var import_ejs = __toESM(require_ejs());
53059
53059
  function renderString2(template, fullData) {
53060
53060
  return import_ejs.default.render(template, fullData) || "";
53061
53061
  }
53062
53062
 
53063
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/index.js
53063
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/index.js
53064
53064
  var EjsAPI = class {
53065
53065
  async renderTemplate(templateResource, target, parameters = {}) {
53066
53066
  if (templateResource._type !== FS_RESOURCE) {
@@ -53093,7 +53093,7 @@ var EjsAPI = class {
53093
53093
  }
53094
53094
  };
53095
53095
 
53096
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-fs@2.3.4_@modern-js+codesmith@2.3.4/node_modules/@modern-js/codesmith-api-fs/dist/esm-node/index.js
53096
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-fs@2.3.5_@modern-js+codesmith@2.3.5/node_modules/@modern-js/codesmith-api-fs/dist/esm-node/index.js
53097
53097
  var import_path2 = __toESM(require("path"));
53098
53098
  var import_utils10 = require("@modern-js/utils");
53099
53099
  var FsAPI = class {
@@ -62677,10 +62677,10 @@ var Schema = (
62677
62677
  }()
62678
62678
  );
62679
62679
 
62680
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
62680
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
62681
62681
  var import_inquirer = __toESM(require_inquirer());
62682
62682
 
62683
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/transform.js
62683
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/transform.js
62684
62684
  var import_lodash = require("@modern-js/utils/lodash");
62685
62685
  function validateSchema(schema) {
62686
62686
  const { type, properties } = schema;
@@ -62772,7 +62772,7 @@ function transformForm(schema, configValue = {}, validateMap, initValue) {
62772
62772
  return getQuestionFromSchema(schema, configValue, validateMap, initValue);
62773
62773
  }
62774
62774
 
62775
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
62775
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
62776
62776
  var compileRule = (rule, scope) => {
62777
62777
  const state = Schema.compile(rule, {
62778
62778
  $self: {},
@@ -62876,7 +62876,7 @@ async function prompt(schema, configValue = {}, validateMap, initValue) {
62876
62876
  return answers;
62877
62877
  }
62878
62878
 
62879
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/inquirer.js
62879
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/inquirer.js
62880
62880
  var CLIReader = class {
62881
62881
  getAnswers() {
62882
62882
  return this.answers;
@@ -62907,7 +62907,7 @@ var CLIReader = class {
62907
62907
  }
62908
62908
  };
62909
62909
 
62910
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
62910
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
62911
62911
  var import_inquirer2 = __toESM(require_inquirer2());
62912
62912
 
62913
62913
  // ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@2.37.2/node_modules/@modern-js/plugin-i18n/dist/esm-node/index.js
@@ -62973,7 +62973,7 @@ var I18n = class {
62973
62973
  }
62974
62974
  };
62975
62975
 
62976
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/zh.js
62976
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/zh.js
62977
62977
  var ZH_LOCALE = {
62978
62978
  environment: {
62979
62979
  node_version: "请升级 Node 版本至 LIS",
@@ -63000,7 +63000,7 @@ var ZH_LOCALE = {
63000
63000
  }
63001
63001
  };
63002
63002
 
63003
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/en.js
63003
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/en.js
63004
63004
  var EN_LOCALE = {
63005
63005
  environment: {
63006
63006
  node_version: "please upgrade node to lts version",
@@ -63027,14 +63027,14 @@ var EN_LOCALE = {
63027
63027
  }
63028
63028
  };
63029
63029
 
63030
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/index.js
63030
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/index.js
63031
63031
  var i18n = new I18n();
63032
63032
  var localeKeys = i18n.init("zh", {
63033
63033
  zh: ZH_LOCALE,
63034
63034
  en: EN_LOCALE
63035
63035
  });
63036
63036
 
63037
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/transform.js
63037
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/transform.js
63038
63038
  var import_lodash4 = require("@modern-js/utils/lodash");
63039
63039
  function transformInquirerSchema(questions, configValue = {}, validateMap = {}, initValue = {}) {
63040
63040
  for (const question of questions) {
@@ -63062,7 +63062,7 @@ function transformInquirerSchema(questions, configValue = {}, validateMap = {},
63062
63062
  return questions;
63063
63063
  }
63064
63064
 
63065
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/checkUseNvm.js
63065
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/checkUseNvm.js
63066
63066
  var import_path4 = __toESM(require("path"));
63067
63067
  var import_utils12 = require("@modern-js/utils");
63068
63068
  var NODE_MAJOR_VERSION_MAP = {
@@ -63110,7 +63110,7 @@ async function checkUseNvm(cwd, logger) {
63110
63110
  }
63111
63111
  }
63112
63112
 
63113
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.4_@modern-js+codesmith@2.3.4_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
63113
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.3.5_@modern-js+codesmith@2.3.5_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
63114
63114
  var AppAPI = class {
63115
63115
  async checkEnvironment(nodeVersion) {
63116
63116
  if (import_utils13.semver.lt(process.versions.node, nodeVersion || "12.22.12")) {
@@ -63350,11 +63350,11 @@ var AppAPI = class {
63350
63350
  }
63351
63351
  };
63352
63352
 
63353
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.4/node_modules/@modern-js/codesmith-api-json/dist/esm-node/index.js
63353
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.5/node_modules/@modern-js/codesmith-api-json/dist/esm-node/index.js
63354
63354
  var import_comment_json2 = __toESM(require_src2());
63355
63355
  var declarationUpdate = __toESM(require_dist());
63356
63356
 
63357
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.4/node_modules/@modern-js/codesmith-api-json/dist/esm-node/utils/index.js
63357
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.5/node_modules/@modern-js/codesmith-api-json/dist/esm-node/utils/index.js
63358
63358
  async function editJson(generatorCore, resource, getNewJsonValue) {
63359
63359
  const originJsonValue = await resource.value();
63360
63360
  const newJsonString = await getNewJsonValue(originJsonValue.content);
@@ -63367,7 +63367,7 @@ async function editJson(generatorCore, resource, getNewJsonValue) {
63367
63367
  return newJsonString;
63368
63368
  }
63369
63369
 
63370
- // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.4/node_modules/@modern-js/codesmith-api-json/dist/esm-node/index.js
63370
+ // ../../../../node_modules/.pnpm/@modern-js+codesmith-api-json@2.3.5/node_modules/@modern-js/codesmith-api-json/dist/esm-node/index.js
63371
63371
  var JsonAPI = class {
63372
63372
  async get(resource) {
63373
63373
  const originJsonValue = await resource.value();
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "modern",
16
16
  "modern.js"
17
17
  ],
18
- "version": "3.3.9",
18
+ "version": "3.3.11",
19
19
  "jsnext:source": "./src/index.ts",
20
20
  "main": "./dist/index.js",
21
21
  "files": [
@@ -23,20 +23,20 @@
23
23
  "/dist/index.js"
24
24
  ],
25
25
  "dependencies": {
26
- "@modern-js/utils": "2.47.0"
26
+ "@modern-js/utils": "2.48.0"
27
27
  },
28
28
  "devDependencies": {
29
- "@modern-js/codesmith": "2.3.4",
30
- "@modern-js/codesmith-api-app": "2.3.4",
31
- "@modern-js/codesmith-api-json": "2.3.4",
29
+ "@modern-js/codesmith": "2.3.5",
30
+ "@modern-js/codesmith-api-app": "2.3.5",
31
+ "@modern-js/codesmith-api-json": "2.3.5",
32
32
  "@types/jest": "^29",
33
33
  "@types/node": "^14",
34
34
  "jest": "^29",
35
35
  "typescript": "^5",
36
- "@modern-js/generator-common": "3.3.9",
37
- "@modern-js/generator-utils": "3.3.9",
38
- "@scripts/jest-config": "2.47.0",
39
- "@scripts/build": "2.47.0"
36
+ "@modern-js/generator-utils": "3.3.11",
37
+ "@modern-js/generator-common": "3.3.11",
38
+ "@scripts/jest-config": "2.48.0",
39
+ "@scripts/build": "2.48.0"
40
40
  },
41
41
  "sideEffects": false,
42
42
  "publishConfig": {