create-vxrn 1.27.1 → 2.0.0-beta.45.1

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 (100) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/dist/cjs/create.cjs +193 -194
  3. package/dist/cjs/create.native.cjs +262 -0
  4. package/dist/cjs/create.native.js +218 -227
  5. package/dist/cjs/create.native.js.map +1 -1
  6. package/dist/cjs/helpers/cloneStarter.cjs +83 -95
  7. package/dist/cjs/helpers/cloneStarter.native.cjs +114 -0
  8. package/dist/cjs/helpers/cloneStarter.native.js +86 -97
  9. package/dist/cjs/helpers/cloneStarter.native.js.map +1 -1
  10. package/dist/cjs/helpers/getProjectName.cjs +56 -65
  11. package/dist/cjs/helpers/getProjectName.native.cjs +75 -0
  12. package/dist/cjs/helpers/getProjectName.native.js +56 -64
  13. package/dist/cjs/helpers/getProjectName.native.js.map +1 -1
  14. package/dist/cjs/helpers/getTemplateInfo.cjs +39 -52
  15. package/dist/cjs/helpers/getTemplateInfo.native.cjs +67 -0
  16. package/dist/cjs/helpers/getTemplateInfo.native.js +48 -60
  17. package/dist/cjs/helpers/getTemplateInfo.native.js.map +1 -1
  18. package/dist/cjs/helpers/installDependencies.cjs +37 -43
  19. package/dist/cjs/helpers/installDependencies.native.cjs +51 -0
  20. package/dist/cjs/helpers/installDependencies.native.js +37 -42
  21. package/dist/cjs/helpers/installDependencies.native.js.map +1 -1
  22. package/dist/cjs/helpers/validateNpmPackage.cjs +25 -36
  23. package/dist/cjs/helpers/validateNpmPackage.native.cjs +42 -0
  24. package/dist/cjs/helpers/validateNpmPackage.native.js +25 -35
  25. package/dist/cjs/helpers/validateNpmPackage.native.js.map +1 -1
  26. package/dist/cjs/index.cjs +60 -69
  27. package/dist/cjs/index.native.cjs +92 -0
  28. package/dist/cjs/index.native.js +61 -69
  29. package/dist/cjs/index.native.js.map +1 -1
  30. package/dist/cjs/steps/bare.cjs +51 -61
  31. package/dist/cjs/steps/bare.native.cjs +121 -0
  32. package/dist/cjs/steps/bare.native.js +71 -82
  33. package/dist/cjs/steps/bare.native.js.map +1 -1
  34. package/dist/cjs/steps/fullstack.cjs +23 -35
  35. package/dist/cjs/steps/fullstack.native.cjs +50 -0
  36. package/dist/cjs/steps/fullstack.native.js +25 -36
  37. package/dist/cjs/steps/fullstack.native.js.map +1 -1
  38. package/dist/cjs/steps/one.cjs +42 -57
  39. package/dist/cjs/steps/one.native.cjs +97 -0
  40. package/dist/cjs/steps/one.native.js +46 -60
  41. package/dist/cjs/steps/one.native.js.map +1 -1
  42. package/dist/cjs/steps/types.cjs +9 -11
  43. package/dist/cjs/steps/types.native.cjs +18 -0
  44. package/dist/cjs/steps/types.native.js +9 -10
  45. package/dist/cjs/steps/types.native.js.map +1 -1
  46. package/dist/cjs/templates.cjs +54 -59
  47. package/dist/cjs/templates.native.cjs +70 -0
  48. package/dist/cjs/templates.native.js +55 -59
  49. package/dist/cjs/templates.native.js.map +1 -1
  50. package/dist/esm/create.mjs +179 -169
  51. package/dist/esm/create.mjs.map +1 -1
  52. package/dist/esm/create.native.js +204 -203
  53. package/dist/esm/create.native.js.map +1 -1
  54. package/dist/esm/helpers/cloneStarter.mjs +71 -77
  55. package/dist/esm/helpers/cloneStarter.mjs.map +1 -1
  56. package/dist/esm/helpers/cloneStarter.native.js +74 -80
  57. package/dist/esm/helpers/cloneStarter.native.js.map +1 -1
  58. package/dist/esm/helpers/getProjectName.mjs +41 -39
  59. package/dist/esm/helpers/getProjectName.mjs.map +1 -1
  60. package/dist/esm/helpers/getProjectName.native.js +41 -39
  61. package/dist/esm/helpers/getProjectName.native.js.map +1 -1
  62. package/dist/esm/helpers/getTemplateInfo.mjs +25 -27
  63. package/dist/esm/helpers/getTemplateInfo.mjs.map +1 -1
  64. package/dist/esm/helpers/getTemplateInfo.native.js +33 -35
  65. package/dist/esm/helpers/getTemplateInfo.native.js.map +1 -1
  66. package/dist/esm/helpers/installDependencies.mjs +25 -25
  67. package/dist/esm/helpers/installDependencies.mjs.map +1 -1
  68. package/dist/esm/helpers/installDependencies.native.js +25 -25
  69. package/dist/esm/helpers/installDependencies.native.js.map +1 -1
  70. package/dist/esm/helpers/validateNpmPackage.mjs +10 -10
  71. package/dist/esm/helpers/validateNpmPackage.mjs.map +1 -1
  72. package/dist/esm/helpers/validateNpmPackage.native.js +10 -10
  73. package/dist/esm/helpers/validateNpmPackage.native.js.map +1 -1
  74. package/dist/esm/index.js +51 -53
  75. package/dist/esm/index.js.map +1 -1
  76. package/dist/esm/index.mjs +51 -53
  77. package/dist/esm/index.mjs.map +1 -1
  78. package/dist/esm/index.native.js +52 -54
  79. package/dist/esm/index.native.js.map +1 -1
  80. package/dist/esm/steps/bare.mjs +35 -36
  81. package/dist/esm/steps/bare.mjs.map +1 -1
  82. package/dist/esm/steps/bare.native.js +55 -58
  83. package/dist/esm/steps/bare.native.js.map +1 -1
  84. package/dist/esm/steps/fullstack.mjs +8 -9
  85. package/dist/esm/steps/fullstack.mjs.map +1 -1
  86. package/dist/esm/steps/fullstack.native.js +10 -11
  87. package/dist/esm/steps/fullstack.native.js.map +1 -1
  88. package/dist/esm/steps/one.mjs +26 -32
  89. package/dist/esm/steps/one.mjs.map +1 -1
  90. package/dist/esm/steps/one.native.js +30 -36
  91. package/dist/esm/steps/one.native.js.map +1 -1
  92. package/dist/esm/steps/types.mjs +0 -2
  93. package/dist/esm/steps/types.native.js +0 -2
  94. package/dist/esm/templates.mjs +40 -34
  95. package/dist/esm/templates.mjs.map +1 -1
  96. package/dist/esm/templates.native.js +40 -34
  97. package/dist/esm/templates.native.js.map +1 -1
  98. package/package.json +4 -4
  99. package/dist/esm/steps/types.mjs.map +0 -1
  100. package/dist/esm/steps/types.native.js.map +0 -1
@@ -0,0 +1,121 @@
1
+ "use strict";
2
+
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __export = (target, all) => {
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, {
18
+ get: () => from[key],
19
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
+ });
21
+ }
22
+ return to;
23
+ };
24
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
25
+ value: mod,
26
+ enumerable: true
27
+ }) : target, mod));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var bare_exports = {};
30
+ __export(bare_exports, {
31
+ default: () => bare_default,
32
+ replaceNameInUTF8File: () => replaceNameInUTF8File
33
+ });
34
+ module.exports = __toCommonJS(bare_exports);
35
+ var import_ansis = __toESM(require("ansis"));
36
+ var import_fs_extra = __toESM(require("fs-extra"));
37
+ var import_path = require("path");
38
+ function shouldIgnoreFile(filePath) {
39
+ return filePath.match(/node_modules|yarn.lock|package-lock.json/g);
40
+ }
41
+ function shouldRenameFile(filePath, nameToReplace) {
42
+ return (0, import_path.basename)(filePath).includes(nameToReplace);
43
+ }
44
+ async function renameFile(filePath, oldName, newName) {
45
+ var newFileName = (0, import_path.join)((0, import_path.dirname)(filePath), (0, import_path.basename)(filePath).replace(new RegExp(oldName, "g"), newName));
46
+ await import_fs_extra.default.rename(filePath, newFileName);
47
+ }
48
+ function walk(current) {
49
+ if (!import_fs_extra.default.lstatSync(current).isDirectory()) {
50
+ return [current];
51
+ }
52
+ var files = import_fs_extra.default.readdirSync(current).map(function(child) {
53
+ return walk((0, import_path.join)(current, child));
54
+ });
55
+ var result = [];
56
+ return result.concat.apply([current], files);
57
+ }
58
+ async function replaceNameInUTF8File(filePath, projectName, templateName) {
59
+ var fileContent = await import_fs_extra.default.readFile(filePath, "utf8");
60
+ var replacedFileContent = fileContent.replace(new RegExp(templateName, "g"), projectName).replace(new RegExp(templateName.toLowerCase(), "g"), projectName.toLowerCase());
61
+ if (fileContent !== replacedFileContent) {
62
+ await import_fs_extra.default.writeFile(filePath, replacedFileContent, "utf8");
63
+ }
64
+ }
65
+ var main = async function(param) {
66
+ var { isFullClone, projectName } = param;
67
+ var placeholderName = "bare";
68
+ var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;
69
+ try {
70
+ for (var _iterator = walk(process.cwd()).reverse()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
71
+ var filePath = _step.value;
72
+ if (shouldIgnoreFile(filePath)) {
73
+ continue;
74
+ }
75
+ if (!(await import_fs_extra.default.stat(filePath)).isDirectory()) {
76
+ await replaceNameInUTF8File(filePath, projectName, "bare");
77
+ }
78
+ if (shouldRenameFile(filePath, placeholderName)) {
79
+ await renameFile(filePath, placeholderName, projectName);
80
+ } else if (shouldRenameFile(filePath, placeholderName.toLowerCase())) {
81
+ await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase());
82
+ }
83
+ }
84
+ } catch (err) {
85
+ _didIteratorError = true;
86
+ _iteratorError = err;
87
+ } finally {
88
+ try {
89
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
90
+ _iterator.return();
91
+ }
92
+ } finally {
93
+ if (_didIteratorError) {
94
+ throw _iteratorError;
95
+ }
96
+ }
97
+ }
98
+ if (isFullClone) {
99
+ console.info(`
100
+ ${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
101
+ \u2022 ${import_ansis.default.green("cd")} ${projectName}
102
+
103
+ ${import_ansis.default.green(`Run instructions for ${import_ansis.default.bold("Android")}:`)}
104
+ \u2022 Have an Android emulator running (quickest way to get started), or a device connected.
105
+ \u2022 npx react-native run-android
106
+
107
+ ${import_ansis.default.blue(`Run instructions for ${import_ansis.default.bold("iOS")}:`)}
108
+ \u2022 Install Cocoapods
109
+ \u2022 bundle install # you need to run this only once in your project.
110
+ \u2022 bundle exec pod install
111
+ \u2022 cd ..
112
+
113
+ \u2022 npx react-native run-ios
114
+ ${import_ansis.default.gray("- or -")}
115
+ \u2022 Open ${projectName}/ios/${projectName}.xcworkspace in Xcode or run "xed -b ios"
116
+ \u2022 Hit the Run button
117
+
118
+ `);
119
+ }
120
+ };
121
+ var bare_default = main;
@@ -7,108 +7,96 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
7
7
  var __getProtoOf = Object.getPrototypeOf;
8
8
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
9
  var __export = (target, all) => {
10
- for (var name in all) __defProp(target, name, {
11
- get: all[name],
12
- enumerable: true
13
- });
10
+ for (var name in all) __defProp(target, name, {
11
+ get: all[name],
12
+ enumerable: true
13
+ });
14
14
  };
15
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, {
18
- get: () => from[key],
19
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
- });
21
- }
22
- return to;
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, {
18
+ get: () => from[key],
19
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
+ });
21
+ }
22
+ return to;
23
23
  };
24
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
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
24
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
25
+ value: mod,
26
+ enumerable: true
32
27
  }) : target, mod));
33
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
34
- value: true
35
- }), mod);
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
36
29
  var bare_exports = {};
37
30
  __export(bare_exports, {
38
- default: () => bare_default,
39
- replaceNameInUTF8File: () => replaceNameInUTF8File
31
+ default: () => bare_default,
32
+ replaceNameInUTF8File: () => replaceNameInUTF8File
40
33
  });
41
34
  module.exports = __toCommonJS(bare_exports);
42
35
  var import_ansis = __toESM(require("ansis"));
43
36
  var import_fs_extra = __toESM(require("fs-extra"));
44
37
  var import_path = require("path");
45
38
  function shouldIgnoreFile(filePath) {
46
- return filePath.match(/node_modules|yarn.lock|package-lock.json/g);
39
+ return filePath.match(/node_modules|yarn.lock|package-lock.json/g);
47
40
  }
48
41
  function shouldRenameFile(filePath, nameToReplace) {
49
- return (0, import_path.basename)(filePath).includes(nameToReplace);
42
+ return (0, import_path.basename)(filePath).includes(nameToReplace);
50
43
  }
51
44
  async function renameFile(filePath, oldName, newName) {
52
- var newFileName = (0, import_path.join)((0, import_path.dirname)(filePath), (0, import_path.basename)(filePath).replace(new RegExp(oldName, "g"), newName));
53
- await import_fs_extra.default.rename(filePath, newFileName);
45
+ var newFileName = (0, import_path.join)((0, import_path.dirname)(filePath), (0, import_path.basename)(filePath).replace(new RegExp(oldName, "g"), newName));
46
+ await import_fs_extra.default.rename(filePath, newFileName);
54
47
  }
55
48
  function walk(current) {
56
- if (!import_fs_extra.default.lstatSync(current).isDirectory()) {
57
- return [current];
58
- }
59
- var files = import_fs_extra.default.readdirSync(current).map(function (child) {
60
- return walk((0, import_path.join)(current, child));
61
- });
62
- var result = [];
63
- return result.concat.apply([current], files);
49
+ if (!import_fs_extra.default.lstatSync(current).isDirectory()) {
50
+ return [current];
51
+ }
52
+ var files = import_fs_extra.default.readdirSync(current).map(function(child) {
53
+ return walk((0, import_path.join)(current, child));
54
+ });
55
+ var result = [];
56
+ return result.concat.apply([current], files);
64
57
  }
65
58
  async function replaceNameInUTF8File(filePath, projectName, templateName) {
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
- }
59
+ var fileContent = await import_fs_extra.default.readFile(filePath, "utf8");
60
+ var replacedFileContent = fileContent.replace(new RegExp(templateName, "g"), projectName).replace(new RegExp(templateName.toLowerCase(), "g"), projectName.toLowerCase());
61
+ if (fileContent !== replacedFileContent) {
62
+ await import_fs_extra.default.writeFile(filePath, replacedFileContent, "utf8");
63
+ }
71
64
  }
72
- var main = async function (param) {
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 {
100
- try {
101
- if (!_iteratorNormalCompletion && _iterator.return != null) {
102
- _iterator.return();
103
- }
104
- } finally {
105
- if (_didIteratorError) {
106
- throw _iteratorError;
107
- }
108
- }
109
- }
110
- if (isFullClone) {
111
- console.info(`
65
+ var main = async function(param) {
66
+ var { isFullClone, projectName } = param;
67
+ var placeholderName = "bare";
68
+ var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;
69
+ try {
70
+ for (var _iterator = walk(process.cwd()).reverse()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
71
+ var filePath = _step.value;
72
+ if (shouldIgnoreFile(filePath)) {
73
+ continue;
74
+ }
75
+ if (!(await import_fs_extra.default.stat(filePath)).isDirectory()) {
76
+ await replaceNameInUTF8File(filePath, projectName, "bare");
77
+ }
78
+ if (shouldRenameFile(filePath, placeholderName)) {
79
+ await renameFile(filePath, placeholderName, projectName);
80
+ } else if (shouldRenameFile(filePath, placeholderName.toLowerCase())) {
81
+ await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase());
82
+ }
83
+ }
84
+ } catch (err) {
85
+ _didIteratorError = true;
86
+ _iteratorError = err;
87
+ } finally {
88
+ try {
89
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
90
+ _iterator.return();
91
+ }
92
+ } finally {
93
+ if (_didIteratorError) {
94
+ throw _iteratorError;
95
+ }
96
+ }
97
+ }
98
+ if (isFullClone) {
99
+ console.info(`
112
100
  ${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
113
101
  \u2022 ${import_ansis.default.green("cd")} ${projectName}
114
102
 
@@ -128,7 +116,8 @@ ${import_ansis.default.blue(`Run instructions for ${import_ansis.default.bold("i
128
116
  \u2022 Hit the Run button
129
117
 
130
118
  `);
131
- }
119
+ }
132
120
  };
133
121
  var bare_default = main;
122
+
134
123
  //# 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"],"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,gBAAOA,CAAAF,QAAA,EAAAG,aAAiB,EAAE;EAC5B,WAAAL,WAAA,CAAAM,QAAA,EAAAJ,QAAA,EAAAK,QAAA,CAAAF,aAAA;AAEA;AACE,eAAMG,WAAcN,QAAA,EAAAO,OAA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AAQ,KAAA;EAEA,IAAAE,eAAY;EACV,IAAAC,yBAAM,GAAsB;IAAAC,iBAAuB,QAAM;IAAAC,cAAA;EAAA,IAC3D;IAEA,KAAI,IAAAC,SAAA,GAAiBzB,IAAA,CAAA0B,OAAU,CAAAC,GAAA,IAAAC,OAAe,CAAG,EAAAC,MAAA,CAAAC,QAAA,KAAAC,KAAA,IAAAT,yBAAA,IAAAS,KAAA,GAAAN,SAAA,CAAAO,IAAA,IAAAC,IAAA,GAAAX,yBAAA;MAC/C,IAAArC,QAAM,GAAA8C,KAAW,CAAA5D,KAAA;MACnB,IAAAa,gBAAW,CAAAC,QAAiB;QAC1B;MACF;MACF,YAAAH,eAAA,CAAAR,OAAA,CAAA4D,IAAA,CAAAjD,QAAA,GAAAkB,WAAA;QAEI,MAAA3B,qBAAa,CAAAS,QAAA,EAAA0B,WAAA;MACf;MACF,IAAAxB,gBAAM,CAAAF,QAAW,EAAAoC,eAAQ;QAAgE,MACrF9B,UAAA,CAAAN,QAAM,EAAAoC,eAAe,EAAAV,WAAW;MAAA,WAAAxB,gBAAA,CAAAF,QAAA,EAAAoC,eAAA,CAAAL,WAAA;QAEpC,MAAAzB,UAAM,CAAAN,QAAM,EAAAoC,eAAA,CAAAL,WAAwB,IAAAL,WAAM,CAAAK,WAAe,GAAG;MAAC;IAAA;EAAA,SAAAmB,GAAA;IAI7DZ,iBAAA,GAAM,IAAK;IAA6CC,cAAA,GAAAW,GAAA;EAAA;IAAA;MAAA,KAAAb,yBAAA,IAAAG,SAAA,CAAAW,MAAA;QAAAX,SAAA,CAAAW,MAAA;MAAA;IAOtD;MAAoB,IAAAb,iBACF;QAAmB,MAAAC,cAAA;MAAA;IAGxC;EACC;EACF,IAAAJ,WAAA;IAEOiB,OAAA,CAAAC,IAAA","ignoreList":[]}
1
+ {"version":3,"file":"bare.native.js","names":[],"sources":["cjs/steps/bare.native.js"],"sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n // If the importer is in node compatibility mode or this is not an ESM\n // file that has been converted to a CommonJS file using a Babel-\n // compatible transform (i.e. \"__esModule\" has not been set), then set\n // \"default\" to the CommonJS \"module.exports\" for node compatibility.\n isNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", { value: mod, enumerable: true }) : target,\n mod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar bare_exports = {};\n__export(bare_exports, {\n default: () => bare_default,\n replaceNameInUTF8File: () => replaceNameInUTF8File\n});\nmodule.exports = __toCommonJS(bare_exports);\nvar import_ansis = __toESM(require(\"ansis\"));\nvar import_fs_extra = __toESM(require(\"fs-extra\"));\nvar import_path = require(\"path\");\nfunction shouldIgnoreFile(filePath) {\n return filePath.match(/node_modules|yarn.lock|package-lock.json/g);\n}\nfunction shouldRenameFile(filePath, nameToReplace) {\n return (0, import_path.basename)(filePath).includes(nameToReplace);\n}\nasync function renameFile(filePath, oldName, newName) {\n var newFileName = (0, import_path.join)((0, import_path.dirname)(filePath), (0, import_path.basename)(filePath).replace(new RegExp(oldName, \"g\"), newName));\n await import_fs_extra.default.rename(filePath, newFileName);\n}\nfunction walk(current) {\n if (!import_fs_extra.default.lstatSync(current).isDirectory()) {\n return [\n current\n ];\n }\n var files = import_fs_extra.default.readdirSync(current).map(function(child) {\n return walk((0, import_path.join)(current, child));\n });\n var result = [];\n return result.concat.apply([\n current\n ], files);\n}\nasync function replaceNameInUTF8File(filePath, projectName, templateName) {\n var fileContent = await import_fs_extra.default.readFile(filePath, \"utf8\");\n var replacedFileContent = fileContent.replace(new RegExp(templateName, \"g\"), projectName).replace(new RegExp(templateName.toLowerCase(), \"g\"), projectName.toLowerCase());\n if (fileContent !== replacedFileContent) {\n await import_fs_extra.default.writeFile(filePath, replacedFileContent, \"utf8\");\n }\n}\nvar main = async function(param) {\n var { isFullClone, projectName } = param;\n var placeholderName = \"bare\";\n var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n try {\n for (var _iterator = walk(process.cwd()).reverse()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n var filePath = _step.value;\n if (shouldIgnoreFile(filePath)) {\n continue;\n }\n if (!(await import_fs_extra.default.stat(filePath)).isDirectory()) {\n await replaceNameInUTF8File(filePath, projectName, \"bare\");\n }\n if (shouldRenameFile(filePath, placeholderName)) {\n await renameFile(filePath, placeholderName, projectName);\n } else if (shouldRenameFile(filePath, placeholderName.toLowerCase())) {\n await renameFile(filePath, placeholderName.toLowerCase(), projectName.toLowerCase());\n }\n }\n } catch (err) {\n _didIteratorError = true;\n _iteratorError = err;\n } finally {\n try {\n if (!_iteratorNormalCompletion && _iterator.return != null) {\n _iterator.return();\n }\n } finally {\n if (_didIteratorError) {\n throw _iteratorError;\n }\n }\n }\n if (isFullClone) {\n console.info(`\n${import_ansis.default.green.bold(\"Done!\")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:\n \\u2022 ${import_ansis.default.green(\"cd\")} ${projectName}\n\n${import_ansis.default.green(`Run instructions for ${import_ansis.default.bold(\"Android\")}:`)}\n \\u2022 Have an Android emulator running (quickest way to get started), or a device connected.\n \\u2022 npx react-native run-android\n\n${import_ansis.default.blue(`Run instructions for ${import_ansis.default.bold(\"iOS\")}:`)}\n \\u2022 Install Cocoapods\n \\u2022 bundle install # you need to run this only once in your project.\n \\u2022 bundle exec pod install\n \\u2022 cd ..\n\n \\u2022 npx react-native run-ios\n ${import_ansis.default.gray(\"- or -\")}\n \\u2022 Open ${projectName}/ios/${projectName}.xcworkspace in Xcode or run \"xed -b ios\"\n \\u2022 Hit the Run button\n\n`);\n }\n};\nvar bare_default = main;\n//# sourceMappingURL=bare.js.map\n"],"mappings":";;;AACA,IAAI,WAAW,OAAO;AACtB,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO;AAC1B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;CAAK,CAAC;AAChE;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC5C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EAClE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GACpC,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QACzC,UAAU,IAAI,KAAK;GAAE,WAAW,KAAK;GAAM,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAAW,CAAC;CACvH;CACA,OAAO;AACT;AACA,IAAI,WAAW,KAAK,YAAY,YAAY,SAAS,OAAO,OAAO,SAAS,aAAa,GAAG,CAAC,IAAI,CAAC,GAAG,YAKnG,cAAc,CAAC,OAAO,CAAC,IAAI,aAAa,UAAU,QAAQ,WAAW;CAAE,OAAO;CAAK,YAAY;AAAK,CAAC,IAAI,QACzG,GACF;AACA,IAAI,gBAAgB,QAAQ,YAAY,UAAU,CAAC,GAAG,cAAc,EAAE,OAAO,KAAK,CAAC,GAAG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Aa,QAAQ,MAAM,wBAAwB,aAAa,QAAQ,KAAK,SAAS,EAAE,EAAE,EAAE;;;;EAI5F,aAAa,QAAQ,KAAK,wBAAwB,aAAa,QAAQ,KAAK,KAAK,EAAE,EAAE,EAAE;;;;;;;IAOrF,aAAa,QAAQ,KAAK,QAAQ,EAAE;gBACxB,YAAY,OAAO,YAAY;;;CAG9C;CACC;AACF;AACA,IAAI,eAAe"}
@@ -5,53 +5,41 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
5
5
  var __getProtoOf = Object.getPrototypeOf;
6
6
  var __hasOwnProp = Object.prototype.hasOwnProperty;
7
7
  var __export = (target, all) => {
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: true
11
- });
8
+ for (var name in all) __defProp(target, name, {
9
+ get: all[name],
10
+ enumerable: true
11
+ });
12
12
  };
13
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, {
16
- get: () => from[key],
17
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
18
- });
19
- }
20
- return to;
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, {
16
+ get: () => from[key],
17
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
18
+ });
19
+ }
20
+ return to;
21
21
  };
22
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
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
22
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
23
+ value: mod,
24
+ enumerable: true
30
25
  }) : target, mod));
31
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
32
- value: true
33
- }), mod);
26
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
34
27
  var fullstack_exports = {};
35
- __export(fullstack_exports, {
36
- default: () => fullstack_default
37
- });
28
+ __export(fullstack_exports, { default: () => fullstack_default });
38
29
  module.exports = __toCommonJS(fullstack_exports);
39
30
  var import_ansis = __toESM(require("ansis"));
40
31
  const packageManager = "yarn";
41
32
  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(`
33
+ const runCommand = (scriptName) => `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
34
+ const main = async ({ isFullClone, projectName }) => {
35
+ if (isFullClone) {
36
+ console.info(`
49
37
  ${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
50
38
  \u2022 ${import_ansis.default.green("cd")} ${projectName}
51
39
  `);
52
- }
53
- console.info(`
40
+ }
41
+ console.info(`
54
42
  To start the dev server, run: ${import_ansis.default.green(runCommand("dev"))}
55
43
  `);
56
44
  };
57
- var fullstack_default = main;
45
+ var fullstack_default = main;
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __export = (target, all) => {
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, {
18
+ get: () => from[key],
19
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
+ });
21
+ }
22
+ return to;
23
+ };
24
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
25
+ value: mod,
26
+ enumerable: true
27
+ }) : target, mod));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var fullstack_exports = {};
30
+ __export(fullstack_exports, { default: () => fullstack_default });
31
+ module.exports = __toCommonJS(fullstack_exports);
32
+ var import_ansis = __toESM(require("ansis"));
33
+ var packageManager = "yarn";
34
+ var useYarn = packageManager === "yarn";
35
+ var runCommand = function(scriptName) {
36
+ return `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
37
+ };
38
+ var main = async function(param) {
39
+ var { isFullClone, projectName } = param;
40
+ if (isFullClone) {
41
+ console.info(`
42
+ ${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
43
+ \u2022 ${import_ansis.default.green("cd")} ${projectName}
44
+ `);
45
+ }
46
+ console.info(`
47
+ To start the dev server, run: ${import_ansis.default.green(runCommand("dev"))}
48
+ `);
49
+ };
50
+ var fullstack_default = main;
@@ -7,57 +7,46 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
7
7
  var __getProtoOf = Object.getPrototypeOf;
8
8
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
9
  var __export = (target, all) => {
10
- for (var name in all) __defProp(target, name, {
11
- get: all[name],
12
- enumerable: true
13
- });
10
+ for (var name in all) __defProp(target, name, {
11
+ get: all[name],
12
+ enumerable: true
13
+ });
14
14
  };
15
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, {
18
- get: () => from[key],
19
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
- });
21
- }
22
- return to;
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, {
18
+ get: () => from[key],
19
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
+ });
21
+ }
22
+ return to;
23
23
  };
24
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
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
24
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
25
+ value: mod,
26
+ enumerable: true
32
27
  }) : target, mod));
33
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
34
- value: true
35
- }), mod);
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
36
29
  var fullstack_exports = {};
37
- __export(fullstack_exports, {
38
- default: () => fullstack_default
39
- });
30
+ __export(fullstack_exports, { default: () => fullstack_default });
40
31
  module.exports = __toCommonJS(fullstack_exports);
41
32
  var import_ansis = __toESM(require("ansis"));
42
33
  var packageManager = "yarn";
43
34
  var useYarn = packageManager === "yarn";
44
- var runCommand = function (scriptName) {
45
- return `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
35
+ var runCommand = function(scriptName) {
36
+ return `${packageManager} ${useYarn ? "" : "run "}${scriptName}`;
46
37
  };
47
- var main = async function (param) {
48
- var {
49
- isFullClone,
50
- projectName
51
- } = param;
52
- if (isFullClone) {
53
- console.info(`
38
+ var main = async function(param) {
39
+ var { isFullClone, projectName } = param;
40
+ if (isFullClone) {
41
+ console.info(`
54
42
  ${import_ansis.default.green.bold("Done!")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:
55
43
  \u2022 ${import_ansis.default.green("cd")} ${projectName}
56
44
  `);
57
- }
58
- console.info(`
45
+ }
46
+ console.info(`
59
47
  To start the dev server, run: ${import_ansis.default.green(runCommand("dev"))}
60
48
  `);
61
49
  };
62
50
  var fullstack_default = main;
51
+
63
52
  //# 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":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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":[]}
1
+ {"version":3,"file":"fullstack.native.js","names":[],"sources":["cjs/steps/fullstack.native.js"],"sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n // If the importer is in node compatibility mode or this is not an ESM\n // file that has been converted to a CommonJS file using a Babel-\n // compatible transform (i.e. \"__esModule\" has not been set), then set\n // \"default\" to the CommonJS \"module.exports\" for node compatibility.\n isNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", { value: mod, enumerable: true }) : target,\n mod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar fullstack_exports = {};\n__export(fullstack_exports, {\n default: () => fullstack_default\n});\nmodule.exports = __toCommonJS(fullstack_exports);\nvar import_ansis = __toESM(require(\"ansis\"));\nvar packageManager = \"yarn\";\nvar useYarn = packageManager === \"yarn\";\nvar runCommand = function(scriptName) {\n return `${packageManager} ${useYarn ? \"\" : \"run \"}${scriptName}`;\n};\nvar main = async function(param) {\n var { isFullClone, projectName } = param;\n if (isFullClone) {\n console.info(`\n${import_ansis.default.green.bold(\"Done!\")} Created a new project under ./${import_ansis.default.greenBright(projectName)} visit your project:\n \\u2022 ${import_ansis.default.green(\"cd\")} ${projectName}\n`);\n }\n console.info(`\nTo start the dev server, run: ${import_ansis.default.green(runCommand(\"dev\"))}\n`);\n};\nvar fullstack_default = main;\n//# sourceMappingURL=fullstack.js.map\n"],"mappings":";;;AACA,IAAI,WAAW,OAAO;AACtB,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO;AAC1B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;CAAK,CAAC;AAChE;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC5C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EAClE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GACpC,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QACzC,UAAU,IAAI,KAAK;GAAE,WAAW,KAAK;GAAM,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAAW,CAAC;CACvH;CACA,OAAO;AACT;AACA,IAAI,WAAW,KAAK,YAAY,YAAY,SAAS,OAAO,OAAO,SAAS,aAAa,GAAG,CAAC,IAAI,CAAC,GAAG,YAKnG,cAAc,CAAC,OAAO,CAAC,IAAI,aAAa,UAAU,QAAQ,WAAW;CAAE,OAAO;CAAK,YAAY;AAAK,CAAC,IAAI,QACzG,GACF;AACA,IAA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