create-vxrn 1.14.4 → 1.14.5
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/.turbo/turbo-build.log +1 -1
- package/dist/cjs/create.cjs +156 -93
- package/dist/cjs/create.native.js +165 -102
- package/dist/cjs/create.native.js.map +1 -1
- package/dist/cjs/helpers/cloneStarter.cjs +77 -45
- package/dist/cjs/helpers/cloneStarter.native.js +79 -47
- package/dist/cjs/helpers/cloneStarter.native.js.map +1 -1
- package/dist/cjs/helpers/getProjectName.cjs +61 -40
- package/dist/cjs/helpers/getProjectName.native.js +67 -46
- package/dist/cjs/helpers/getProjectName.native.js.map +1 -1
- package/dist/cjs/helpers/getTemplateInfo.cjs +50 -35
- package/dist/cjs/helpers/getTemplateInfo.native.js +59 -44
- package/dist/cjs/helpers/getTemplateInfo.native.js.map +1 -1
- package/dist/cjs/helpers/installDependencies.cjs +16 -12
- package/dist/cjs/helpers/installDependencies.native.js +19 -15
- package/dist/cjs/helpers/installDependencies.native.js.map +1 -1
- package/dist/cjs/helpers/validateNpmPackage.cjs +31 -26
- package/dist/cjs/helpers/validateNpmPackage.native.js +31 -26
- package/dist/cjs/helpers/validateNpmPackage.native.js.map +1 -1
- package/dist/cjs/index.cjs +39 -25
- package/dist/cjs/index.native.js +39 -26
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/cjs/steps/bare.cjs +53 -32
- package/dist/cjs/steps/bare.native.js +75 -52
- package/dist/cjs/steps/bare.native.js.map +1 -1
- package/dist/cjs/steps/fullstack.cjs +37 -32
- package/dist/cjs/steps/fullstack.native.js +42 -37
- package/dist/cjs/steps/fullstack.native.js.map +1 -1
- package/dist/cjs/steps/one.cjs +65 -47
- package/dist/cjs/steps/one.native.js +70 -52
- package/dist/cjs/steps/one.native.js.map +1 -1
- package/dist/cjs/steps/types.cjs +7 -5
- package/dist/cjs/steps/types.native.js +7 -5
- package/dist/cjs/steps/types.native.js.map +1 -1
- package/dist/cjs/templates.cjs +35 -33
- package/dist/cjs/templates.native.js +59 -57
- package/dist/cjs/templates.native.js.map +1 -1
- package/dist/esm/create.mjs +112 -51
- package/dist/esm/create.mjs.map +1 -1
- package/dist/esm/create.native.js +127 -66
- package/dist/esm/create.native.js.map +1 -1
- package/dist/esm/helpers/cloneStarter.mjs +60 -30
- package/dist/esm/helpers/cloneStarter.mjs.map +1 -1
- package/dist/esm/helpers/cloneStarter.native.js +62 -32
- package/dist/esm/helpers/cloneStarter.native.js.map +1 -1
- package/dist/esm/helpers/getProjectName.mjs +33 -14
- package/dist/esm/helpers/getProjectName.mjs.map +1 -1
- package/dist/esm/helpers/getProjectName.native.js +33 -14
- package/dist/esm/helpers/getProjectName.native.js.map +1 -1
- package/dist/esm/helpers/getTemplateInfo.mjs +24 -11
- package/dist/esm/helpers/getTemplateInfo.mjs.map +1 -1
- package/dist/esm/helpers/getTemplateInfo.native.js +32 -19
- package/dist/esm/helpers/getTemplateInfo.native.js.map +1 -1
- package/dist/esm/helpers/installDependencies.mjs +4 -2
- package/dist/esm/helpers/installDependencies.mjs.map +1 -1
- package/dist/esm/helpers/installDependencies.native.js +7 -5
- package/dist/esm/helpers/installDependencies.native.js.map +1 -1
- package/dist/esm/helpers/validateNpmPackage.mjs +7 -4
- package/dist/esm/helpers/validateNpmPackage.mjs.map +1 -1
- package/dist/esm/helpers/validateNpmPackage.native.js +7 -4
- package/dist/esm/helpers/validateNpmPackage.native.js.map +1 -1
- package/dist/esm/index.js +22 -10
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/index.mjs +22 -10
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/index.native.js +22 -11
- package/dist/esm/index.native.js.map +1 -1
- package/dist/esm/steps/bare.mjs +26 -7
- package/dist/esm/steps/bare.mjs.map +1 -1
- package/dist/esm/steps/bare.native.js +48 -27
- package/dist/esm/steps/bare.native.js.map +1 -1
- package/dist/esm/steps/fullstack.mjs +13 -10
- package/dist/esm/steps/fullstack.mjs.map +1 -1
- package/dist/esm/steps/fullstack.native.js +17 -14
- package/dist/esm/steps/fullstack.native.js.map +1 -1
- package/dist/esm/steps/one.mjs +37 -21
- package/dist/esm/steps/one.mjs.map +1 -1
- package/dist/esm/steps/one.native.js +41 -25
- package/dist/esm/steps/one.native.js.map +1 -1
- package/dist/esm/templates.mjs +11 -11
- package/dist/esm/templates.native.js +11 -11
- package/package.json +3 -3
package/dist/cjs/steps/bare.cjs
CHANGED
|
@@ -2,42 +2,44 @@ var __create = Object.create;
|
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getProtoOf = Object.getPrototypeOf
|
|
6
|
-
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
for (var name in all) __defProp(target, name, {
|
|
9
|
+
get: all[name],
|
|
10
|
+
enumerable: true
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
23
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
24
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
25
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
26
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
27
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
28
|
+
value: mod,
|
|
29
|
+
enumerable: true
|
|
30
|
+
}) : target, mod));
|
|
31
|
+
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
32
|
+
value: true
|
|
33
|
+
}), mod);
|
|
32
34
|
var bare_exports = {};
|
|
33
35
|
__export(bare_exports, {
|
|
34
36
|
default: () => bare_default,
|
|
35
37
|
replaceNameInUTF8File: () => replaceNameInUTF8File
|
|
36
38
|
});
|
|
37
39
|
module.exports = __toCommonJS(bare_exports);
|
|
38
|
-
var import_ansis = __toESM(require("ansis"))
|
|
39
|
-
|
|
40
|
-
|
|
40
|
+
var import_ansis = __toESM(require("ansis"));
|
|
41
|
+
var import_fs_extra = __toESM(require("fs-extra"));
|
|
42
|
+
var import_node_path = require("node:path");
|
|
41
43
|
function shouldIgnoreFile(filePath) {
|
|
42
44
|
return filePath.match(/node_modules|yarn.lock|package-lock.json/g);
|
|
43
45
|
}
|
|
@@ -49,22 +51,40 @@ async function renameFile(filePath, oldName, newName) {
|
|
|
49
51
|
await import_fs_extra.default.rename(filePath, newFileName);
|
|
50
52
|
}
|
|
51
53
|
function walk(current) {
|
|
52
|
-
if (!import_fs_extra.default.lstatSync(current).isDirectory())
|
|
54
|
+
if (!import_fs_extra.default.lstatSync(current).isDirectory()) {
|
|
55
|
+
return [current];
|
|
56
|
+
}
|
|
53
57
|
const files = import_fs_extra.default.readdirSync(current).map(child => walk((0, import_node_path.join)(current, child)));
|
|
54
|
-
|
|
58
|
+
const result = [];
|
|
59
|
+
return result.concat.apply([current], files);
|
|
55
60
|
}
|
|
56
61
|
async function replaceNameInUTF8File(filePath, projectName, templateName) {
|
|
57
|
-
const fileContent = await import_fs_extra.default.readFile(filePath, "utf8")
|
|
58
|
-
|
|
59
|
-
fileContent !== replacedFileContent
|
|
62
|
+
const fileContent = await import_fs_extra.default.readFile(filePath, "utf8");
|
|
63
|
+
const replacedFileContent = fileContent.replace(new RegExp(templateName, "g"), projectName).replace(new RegExp(templateName.toLowerCase(), "g"), projectName.toLowerCase());
|
|
64
|
+
if (fileContent !== replacedFileContent) {
|
|
65
|
+
await import_fs_extra.default.writeFile(filePath, replacedFileContent, "utf8");
|
|
66
|
+
}
|
|
60
67
|
}
|
|
61
68
|
const main = async ({
|
|
62
69
|
isFullClone,
|
|
63
70
|
projectName
|
|
64
71
|
}) => {
|
|
65
72
|
const placeholderName = "bare";
|
|
66
|
-
for (const filePath of walk(process.cwd()).reverse())
|
|
67
|
-
|
|
73
|
+
for (const filePath of walk(process.cwd()).reverse()) {
|
|
74
|
+
if (shouldIgnoreFile(filePath)) {
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
if (!(await import_fs_extra.default.stat(filePath)).isDirectory()) {
|
|
78
|
+
await replaceNameInUTF8File(filePath, projectName, "bare");
|
|
79
|
+
}
|
|
80
|
+
if (shouldRenameFile(filePath, placeholderName)) {
|
|
81
|
+
await renameFile(filePath, placeholderName, projectName);
|
|
82
|
+
} else if (shouldRenameFile(filePath, placeholderName.toLowerCase())) {
|
|
83
|
+
await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase());
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
if (isFullClone) {
|
|
87
|
+
console.info(`
|
|
68
88
|
${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
|
|
69
89
|
\u2022 ${import_ansis.default.green("cd")} ${projectName}
|
|
70
90
|
|
|
@@ -84,5 +104,6 @@ ${import_ansis.default.blue(`Run instructions for ${import_ansis.default.bold("i
|
|
|
84
104
|
\u2022 Hit the Run button
|
|
85
105
|
|
|
86
106
|
`);
|
|
107
|
+
}
|
|
87
108
|
};
|
|
88
109
|
var bare_default = main;
|
|
@@ -4,42 +4,44 @@ var __create = Object.create;
|
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
5
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
6
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
-
var __getProtoOf = Object.getPrototypeOf
|
|
8
|
-
|
|
7
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
9
|
var __export = (target, all) => {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
10
|
+
for (var name in all) __defProp(target, name, {
|
|
11
|
+
get: all[name],
|
|
12
|
+
enumerable: true
|
|
13
|
+
});
|
|
14
|
+
};
|
|
15
|
+
var __copyProps = (to, from, except, desc) => {
|
|
16
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
17
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
18
|
get: () => from[key],
|
|
18
19
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
20
|
});
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
}
|
|
22
|
+
return to;
|
|
23
|
+
};
|
|
22
24
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
25
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
26
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
27
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
30
|
+
value: mod,
|
|
31
|
+
enumerable: true
|
|
32
|
+
}) : target, mod));
|
|
33
|
+
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
34
|
+
value: true
|
|
35
|
+
}), mod);
|
|
34
36
|
var bare_exports = {};
|
|
35
37
|
__export(bare_exports, {
|
|
36
38
|
default: () => bare_default,
|
|
37
39
|
replaceNameInUTF8File: () => replaceNameInUTF8File
|
|
38
40
|
});
|
|
39
41
|
module.exports = __toCommonJS(bare_exports);
|
|
40
|
-
var import_ansis = __toESM(require("ansis"))
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
var import_ansis = __toESM(require("ansis"));
|
|
43
|
+
var import_fs_extra = __toESM(require("fs-extra"));
|
|
44
|
+
var import_path = require("path");
|
|
43
45
|
function shouldIgnoreFile(filePath) {
|
|
44
46
|
return filePath.match(/node_modules|yarn.lock|package-lock.json/g);
|
|
45
47
|
}
|
|
@@ -51,42 +53,62 @@ async function renameFile(filePath, oldName, newName) {
|
|
|
51
53
|
await import_fs_extra.default.rename(filePath, newFileName);
|
|
52
54
|
}
|
|
53
55
|
function walk(current) {
|
|
54
|
-
if (!import_fs_extra.default.lstatSync(current).isDirectory())
|
|
56
|
+
if (!import_fs_extra.default.lstatSync(current).isDirectory()) {
|
|
57
|
+
return [current];
|
|
58
|
+
}
|
|
55
59
|
var files = import_fs_extra.default.readdirSync(current).map(function (child) {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
60
|
+
return walk((0, import_path.join)(current, child));
|
|
61
|
+
});
|
|
62
|
+
var result = [];
|
|
59
63
|
return result.concat.apply([current], files);
|
|
60
64
|
}
|
|
61
65
|
async function replaceNameInUTF8File(filePath, projectName, templateName) {
|
|
62
|
-
var fileContent = await import_fs_extra.default.readFile(filePath, "utf8")
|
|
63
|
-
|
|
64
|
-
fileContent !== replacedFileContent
|
|
66
|
+
var fileContent = await import_fs_extra.default.readFile(filePath, "utf8");
|
|
67
|
+
var replacedFileContent = fileContent.replace(new RegExp(templateName, "g"), projectName).replace(new RegExp(templateName.toLowerCase(), "g"), projectName.toLowerCase());
|
|
68
|
+
if (fileContent !== replacedFileContent) {
|
|
69
|
+
await import_fs_extra.default.writeFile(filePath, replacedFileContent, "utf8");
|
|
70
|
+
}
|
|
65
71
|
}
|
|
66
72
|
var main = async function (param) {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
73
|
+
var {
|
|
74
|
+
isFullClone,
|
|
75
|
+
projectName
|
|
76
|
+
} = param;
|
|
77
|
+
var placeholderName = "bare";
|
|
78
|
+
var _iteratorNormalCompletion = true,
|
|
79
|
+
_didIteratorError = false,
|
|
80
|
+
_iteratorError = void 0;
|
|
81
|
+
try {
|
|
82
|
+
for (var _iterator = walk(process.cwd()).reverse()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
83
|
+
var filePath = _step.value;
|
|
84
|
+
if (shouldIgnoreFile(filePath)) {
|
|
85
|
+
continue;
|
|
86
|
+
}
|
|
87
|
+
if (!(await import_fs_extra.default.stat(filePath)).isDirectory()) {
|
|
88
|
+
await replaceNameInUTF8File(filePath, projectName, "bare");
|
|
89
|
+
}
|
|
90
|
+
if (shouldRenameFile(filePath, placeholderName)) {
|
|
91
|
+
await renameFile(filePath, placeholderName, projectName);
|
|
92
|
+
} else if (shouldRenameFile(filePath, placeholderName.toLowerCase())) {
|
|
93
|
+
await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase());
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
} catch (err) {
|
|
97
|
+
_didIteratorError = true;
|
|
98
|
+
_iteratorError = err;
|
|
99
|
+
} finally {
|
|
75
100
|
try {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
shouldIgnoreFile(filePath) || ((await import_fs_extra.default.stat(filePath)).isDirectory() || (await replaceNameInUTF8File(filePath, projectName, "bare")), shouldRenameFile(filePath, placeholderName) ? await renameFile(filePath, placeholderName, projectName) : shouldRenameFile(filePath, placeholderName.toLowerCase()) && (await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase())));
|
|
101
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
102
|
+
_iterator.return();
|
|
79
103
|
}
|
|
80
|
-
} catch (err) {
|
|
81
|
-
_didIteratorError = !0, _iteratorError = err;
|
|
82
104
|
} finally {
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
} finally {
|
|
86
|
-
if (_didIteratorError) throw _iteratorError;
|
|
105
|
+
if (_didIteratorError) {
|
|
106
|
+
throw _iteratorError;
|
|
87
107
|
}
|
|
88
108
|
}
|
|
89
|
-
|
|
109
|
+
}
|
|
110
|
+
if (isFullClone) {
|
|
111
|
+
console.info(`
|
|
90
112
|
${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
|
|
91
113
|
\u2022 ${import_ansis.default.green("cd")} ${projectName}
|
|
92
114
|
|
|
@@ -106,6 +128,7 @@ ${import_ansis.default.blue(`Run instructions for ${import_ansis.default.bold("i
|
|
|
106
128
|
\u2022 Hit the Run button
|
|
107
129
|
|
|
108
130
|
`);
|
|
109
|
-
}
|
|
110
|
-
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
var bare_default = main;
|
|
111
134
|
//# sourceMappingURL=bare.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","bare_exports","__export","default","bare_default","replaceNameInUTF8File","module","exports","import_ansis","__toESM","require","import_fs_extra","import_path","shouldIgnoreFile","filePath","match","shouldRenameFile","nameToReplace","basename","includes","renameFile","oldName","newName","newFileName","join","dirname","replace","RegExp","rename","walk","current","lstatSync","isDirectory","files","readdirSync","map","child","result","concat","apply","projectName","templateName","fileContent","readFile","replacedFileContent","toLowerCase","writeFile","main","param","isFullClone","placeholderName","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","process","cwd","reverse","Symbol","iterator","_step","next","done","stat","err","return","console","info"
|
|
1
|
+
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","bare_exports","__export","default","bare_default","replaceNameInUTF8File","module","exports","import_ansis","__toESM","require","import_fs_extra","import_path","shouldIgnoreFile","filePath","match","shouldRenameFile","nameToReplace","basename","includes","renameFile","oldName","newName","newFileName","join","dirname","replace","RegExp","rename","walk","current","lstatSync","isDirectory","files","readdirSync","map","child","result","concat","apply","projectName","templateName","fileContent","readFile","replacedFileContent","toLowerCase","writeFile","main","param","isFullClone","placeholderName","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","process","cwd","reverse","Symbol","iterator","_step","next","done","stat","err","return","console","info"],"sources":["../../../src/steps/bare.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,YAAA;AAAAC,QAAA,CAAAD,YAAA;EAAAE,OAAA,EAAAA,CAAA,KAAAC,YAAA;EAAAC,qBAAA,EAAAA,CAAA,KAAAA;AAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAX,YAAkB,CAAAK,YAAA;AAClB,IAAAO,YAAA,GAAAC,OAAe,CAAAC,OAAA;AACf,IAAAC,eAAA,GAAAF,OAAwC,CAAAC,OAAA;AAGxC,IAAAE,WAAS,GAAAF,OAAA,CAAiB;AACxB,SAAOG,gBAAeA,CAAAC,QAAA;EACxB,OAAAA,QAAA,CAAAC,KAAA;AAEA;AACE,SAAAC,g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A;IAEOiB,OAAA,CAAAC,IAAA","ignoreList":[]}
|
|
@@ -2,51 +2,56 @@ var __create = Object.create;
|
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getProtoOf = Object.getPrototypeOf
|
|
6
|
-
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
for (var name in all) __defProp(target, name, {
|
|
9
|
+
get: all[name],
|
|
10
|
+
enumerable: true
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
23
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
24
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
25
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
26
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
27
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
28
|
+
value: mod,
|
|
29
|
+
enumerable: true
|
|
30
|
+
}) : target, mod));
|
|
31
|
+
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
32
|
+
value: true
|
|
33
|
+
}), mod);
|
|
32
34
|
var fullstack_exports = {};
|
|
33
35
|
__export(fullstack_exports, {
|
|
34
36
|
default: () => fullstack_default
|
|
35
37
|
});
|
|
36
38
|
module.exports = __toCommonJS(fullstack_exports);
|
|
37
39
|
var import_ansis = __toESM(require("ansis"));
|
|
38
|
-
const packageManager = "yarn"
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
40
|
+
const packageManager = "yarn";
|
|
41
|
+
const useYarn = packageManager === "yarn";
|
|
42
|
+
const runCommand = scriptName => `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
|
|
43
|
+
const main = async ({
|
|
44
|
+
isFullClone,
|
|
45
|
+
projectName
|
|
46
|
+
}) => {
|
|
47
|
+
if (isFullClone) {
|
|
48
|
+
console.info(`
|
|
46
49
|
${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
|
|
47
50
|
\u2022 ${import_ansis.default.green("cd")} ${projectName}
|
|
48
|
-
`)
|
|
51
|
+
`);
|
|
52
|
+
}
|
|
53
|
+
console.info(`
|
|
49
54
|
To start the dev server, run: ${import_ansis.default.green(runCommand("dev"))}
|
|
50
55
|
`);
|
|
51
|
-
|
|
56
|
+
};
|
|
52
57
|
var fullstack_default = main;
|
|
@@ -4,55 +4,60 @@ var __create = Object.create;
|
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
5
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
6
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
-
var __getProtoOf = Object.getPrototypeOf
|
|
8
|
-
|
|
7
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
9
|
var __export = (target, all) => {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
10
|
+
for (var name in all) __defProp(target, name, {
|
|
11
|
+
get: all[name],
|
|
12
|
+
enumerable: true
|
|
13
|
+
});
|
|
14
|
+
};
|
|
15
|
+
var __copyProps = (to, from, except, desc) => {
|
|
16
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
17
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
18
|
get: () => from[key],
|
|
18
19
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
20
|
});
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
}
|
|
22
|
+
return to;
|
|
23
|
+
};
|
|
22
24
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
25
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
26
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
27
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
30
|
+
value: mod,
|
|
31
|
+
enumerable: true
|
|
32
|
+
}) : target, mod));
|
|
33
|
+
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
34
|
+
value: true
|
|
35
|
+
}), mod);
|
|
34
36
|
var fullstack_exports = {};
|
|
35
37
|
__export(fullstack_exports, {
|
|
36
38
|
default: () => fullstack_default
|
|
37
39
|
});
|
|
38
40
|
module.exports = __toCommonJS(fullstack_exports);
|
|
39
|
-
var import_ansis = __toESM(require("ansis"))
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
41
|
+
var import_ansis = __toESM(require("ansis"));
|
|
42
|
+
var packageManager = "yarn";
|
|
43
|
+
var useYarn = packageManager === "yarn";
|
|
44
|
+
var runCommand = function (scriptName) {
|
|
45
|
+
return `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
|
|
46
|
+
};
|
|
47
|
+
var main = async function (param) {
|
|
48
|
+
var {
|
|
49
|
+
isFullClone,
|
|
50
|
+
projectName
|
|
51
|
+
} = param;
|
|
52
|
+
if (isFullClone) {
|
|
53
|
+
console.info(`
|
|
51
54
|
${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
|
|
52
55
|
\u2022 ${import_ansis.default.green("cd")} ${projectName}
|
|
53
|
-
`)
|
|
56
|
+
`);
|
|
57
|
+
}
|
|
58
|
+
console.info(`
|
|
54
59
|
To start the dev server, run: ${import_ansis.default.green(runCommand("dev"))}
|
|
55
60
|
`);
|
|
56
|
-
|
|
57
|
-
|
|
61
|
+
};
|
|
62
|
+
var fullstack_default = main;
|
|
58
63
|
//# sourceMappingURL=fullstack.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","fullstack_exports","__export","default","fullstack_default","module","exports","import_ansis","__toESM","require","packageManager","useYarn","runCommand","scriptName","main","param","isFullClone","projectName","console","info","green","bold","greenBright"],"sources":["../../../src/steps/fullstack.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","fullstack_exports","__export","default","fullstack_default","module","exports","import_ansis","__toESM","require","packageManager","useYarn","runCommand","scriptName","main","param","isFullClone","projectName","console","info","green","bold","greenBright"],"sources":["../../../src/steps/fullstack.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,iBAAA;AAAAC,QAAA,CAAAD,iBAAA;EAAAE,OAAA,EAAAA,CAAA,KAAAC;AAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAV,YAAkB,CAAAK,iBAAA;AAIlB,IAAAM,YAAM,GAAAC,OAAiB,CAAAC,OAAA;AACvB,IAAAC,cAAgB;AAEhB,IAAAC,OAAM,GAAAD,cAAc,WACf;AAEL,IAAAE,UAAyB,YAAAA,CAASC,UAAa;EAC7C,OAAI,GAAAH,cAAa,IAAAC,OAAA,iBAAAE,UAAA;AACf;AAAa,IACfC,IAAA,kBAAAA,CAAMC,KAAM;EAA6E;IAAAC,WACtF;IAAAC;EAAM,IAAMF,KAAK;EACrB,IAAAC,WAAA;IACCE,OAAA,CAAAC,IAAA;AACA,EAAAZ,YAAQ,CAAKJ,OAAA,CAAAiB,KAAA,CAAAC,IAAA,2CAAAd,YAAA,CAAAJ,OAAA,CAAAmB,WAAA,CAAAL,WAAA;AAAA,UAAAV,YAAA,CAAAJ,OAAA,CAAAiB,KACiB,UAAAH,WAAM;AAAwB,CAC7D;EACD;EAEAC,OAAO,CAAAC,IAAA","ignoreList":[]}
|