vona-cli-set-api 1.0.423 → 1.0.426
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/dist/index.js
CHANGED
|
@@ -1068,13 +1068,12 @@ class CliCreateBean extends BeanCliBase {
|
|
|
1068
1068
|
const boilerplates = this._getBoilerplatesOrSnippets('boilerplate', argv.boilerplate);
|
|
1069
1069
|
const snippetsName = snippets[`${sceneName}:${argv.beanName}`] || snippets[sceneName];
|
|
1070
1070
|
const boilerplateName = boilerplates[`${sceneName}:${argv.beanName}`] || boilerplates[sceneName];
|
|
1071
|
-
const boilerplatePath = `cli/${boilerplateName}`;
|
|
1072
1071
|
// render
|
|
1073
1072
|
await this.template.renderBoilerplateAndSnippets({
|
|
1074
1073
|
targetDir: beanDir,
|
|
1075
1074
|
setName: __ThisSetName__,
|
|
1076
1075
|
snippetsPath: snippetsName,
|
|
1077
|
-
boilerplatePath
|
|
1076
|
+
boilerplatePath: boilerplateName
|
|
1078
1077
|
});
|
|
1079
1078
|
// tools.metadata
|
|
1080
1079
|
if (!argv.nometadata) {
|
|
@@ -1092,7 +1091,7 @@ class CliCreateBean extends BeanCliBase {
|
|
|
1092
1091
|
const onionSceneMeta = onionScenesMeta[sceneName];
|
|
1093
1092
|
const scenePath = onionSceneMeta[type2];
|
|
1094
1093
|
if (scenePath) {
|
|
1095
|
-
result[sceneName] =
|
|
1094
|
+
result[sceneName] = this._combineBoilerplatesOrSnippetsPath(type, onionSceneMeta.module.root, scenePath);
|
|
1096
1095
|
}
|
|
1097
1096
|
}
|
|
1098
1097
|
// metas
|
|
@@ -1101,11 +1100,21 @@ class CliCreateBean extends BeanCliBase {
|
|
|
1101
1100
|
const onionMetaMeta = onionMetasMeta[sceneName];
|
|
1102
1101
|
const scenePath = onionMetaMeta[type2];
|
|
1103
1102
|
if (scenePath) {
|
|
1104
|
-
result[`meta:${sceneName}`] =
|
|
1103
|
+
result[`meta:${sceneName}`] = this._combineBoilerplatesOrSnippetsPath(type, onionMetaMeta.module.root, scenePath);
|
|
1105
1104
|
}
|
|
1106
1105
|
}
|
|
1107
1106
|
return result;
|
|
1108
1107
|
}
|
|
1108
|
+
_combineBoilerplatesOrSnippetsPath(type, moduleRoot, scenePath) {
|
|
1109
|
+
if (type === 'boilerplate') {
|
|
1110
|
+
return path.join(moduleRoot, 'cli', scenePath);
|
|
1111
|
+
}
|
|
1112
|
+
let snippetsPath = path.join(moduleRoot, 'dist-cli', scenePath);
|
|
1113
|
+
if (!fse.existsSync(snippetsPath)) {
|
|
1114
|
+
snippetsPath = path.join(moduleRoot, 'cli', scenePath);
|
|
1115
|
+
}
|
|
1116
|
+
return snippetsPath;
|
|
1117
|
+
}
|
|
1109
1118
|
}
|
|
1110
1119
|
|
|
1111
1120
|
class CliCreateModule extends BeanCliBase {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vona-cli-set-api",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.426",
|
|
5
5
|
"description": "vona cli-set-api",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"@babel/plugin-proposal-decorators": "^7.25.9",
|
|
34
34
|
"@babel/plugin-transform-class-properties": "^7.25.9",
|
|
35
35
|
"@babel/plugin-transform-typescript": "^7.26.8",
|
|
36
|
-
"@cabloy/cli": "^3.0.
|
|
36
|
+
"@cabloy/cli": "^3.0.75",
|
|
37
37
|
"@cabloy/dotenv": "^1.1.12",
|
|
38
38
|
"@cabloy/extend": "^3.1.11",
|
|
39
39
|
"@cabloy/module-glob": "^5.2.35",
|