create-awesome-node-app 0.6.7 → 0.7.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.
- package/README.md +188 -160
- package/dist/index.cjs +27 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +27 -12
- package/dist/index.js.map +1 -1
- package/package.json +7 -6
- package/dist/chunk-SIARO2CH.js +0 -123
package/dist/index.js
CHANGED
|
@@ -1572,7 +1572,9 @@ import {
|
|
|
1572
1572
|
import { isCI } from "ci-info";
|
|
1573
1573
|
import prompts from "prompts";
|
|
1574
1574
|
import yargs from "yargs";
|
|
1575
|
-
prompts.override(
|
|
1575
|
+
prompts.override(
|
|
1576
|
+
yargs(process.argv.slice(2)).help(false).version(false).argv
|
|
1577
|
+
);
|
|
1576
1578
|
var PACKAGE_MANAGERS = ["npm", "yarn", "pnpm"];
|
|
1577
1579
|
var isValidUrl = (url) => {
|
|
1578
1580
|
try {
|
|
@@ -1816,19 +1818,24 @@ var processInteractiveOptions = async (options) => {
|
|
|
1816
1818
|
}
|
|
1817
1819
|
return nextOptions;
|
|
1818
1820
|
};
|
|
1821
|
+
var resolveInteractiveMode = (options, ci = isCI) => {
|
|
1822
|
+
const explicit = options.interactive;
|
|
1823
|
+
if (explicit === true) return true;
|
|
1824
|
+
if (explicit === false) return false;
|
|
1825
|
+
return !ci;
|
|
1826
|
+
};
|
|
1819
1827
|
var getCnaOptions = async (options) => {
|
|
1820
|
-
const shouldUseInteractiveMode =
|
|
1828
|
+
const shouldUseInteractiveMode = resolveInteractiveMode(options);
|
|
1821
1829
|
if (shouldUseInteractiveMode) {
|
|
1822
|
-
return processInteractiveOptions(options);
|
|
1823
|
-
} else {
|
|
1824
|
-
return processNonInteractiveOptions(options);
|
|
1830
|
+
return processInteractiveOptions({ ...options, interactive: true });
|
|
1825
1831
|
}
|
|
1832
|
+
return processNonInteractiveOptions(options);
|
|
1826
1833
|
};
|
|
1827
1834
|
|
|
1828
1835
|
// package.json
|
|
1829
1836
|
var package_default = {
|
|
1830
1837
|
name: "create-awesome-node-app",
|
|
1831
|
-
version: "0.
|
|
1838
|
+
version: "0.7.1",
|
|
1832
1839
|
type: "module",
|
|
1833
1840
|
description: "Command line tool to create Node apps with a lot of different templates and extensions.",
|
|
1834
1841
|
license: "MIT",
|
|
@@ -1882,8 +1889,8 @@ var package_default = {
|
|
|
1882
1889
|
"test:src": "npm run test"
|
|
1883
1890
|
},
|
|
1884
1891
|
dependencies: {
|
|
1885
|
-
"@create-node-app/core": "^0.5.
|
|
1886
|
-
axios: "^1.
|
|
1892
|
+
"@create-node-app/core": "^0.5.7",
|
|
1893
|
+
axios: "^1.13.6",
|
|
1887
1894
|
"ci-info": "^4.3.0",
|
|
1888
1895
|
commander: "^14.0.1",
|
|
1889
1896
|
prompts: "^2.4.2",
|
|
@@ -1891,16 +1898,17 @@ var package_default = {
|
|
|
1891
1898
|
yargs: "^18.0.0"
|
|
1892
1899
|
},
|
|
1893
1900
|
devDependencies: {
|
|
1901
|
+
"@create-node-app/core": "^0.5.7",
|
|
1894
1902
|
"@create-node-app/eslint-config-ts": "*",
|
|
1895
1903
|
"@types/node": "^24.5.2",
|
|
1896
1904
|
"@types/prompts": "^2.4.9",
|
|
1897
|
-
"@types/yargs": "^17.0.33",
|
|
1898
1905
|
"@types/semver": "^7.5.8",
|
|
1899
|
-
|
|
1906
|
+
"@types/yargs": "^17.0.33",
|
|
1900
1907
|
eslint: "^9.35.0",
|
|
1901
1908
|
"eslint-config-turbo": "^2.5.6",
|
|
1902
|
-
tsup: "^8.5.0",
|
|
1903
1909
|
"eslint-plugin-turbo": "^2.5.6",
|
|
1910
|
+
nock: "^13.5.4",
|
|
1911
|
+
tsup: "^8.5.0",
|
|
1904
1912
|
tsx: "^4.19.0"
|
|
1905
1913
|
}
|
|
1906
1914
|
};
|
|
@@ -1994,7 +2002,14 @@ var main = async () => {
|
|
|
1994
2002
|
).option(
|
|
1995
2003
|
"--addons [extensions...]",
|
|
1996
2004
|
"specify extensions to apply for the boilerplate generation"
|
|
1997
|
-
).option("--use-yarn", "use yarn instead of npm or pnpm").option("--use-pnpm", "use pnpm instead of yarn or npm").option(
|
|
2005
|
+
).option("--use-yarn", "use yarn instead of npm or pnpm").option("--use-pnpm", "use pnpm instead of yarn or npm").option(
|
|
2006
|
+
"--interactive",
|
|
2007
|
+
"force interactive mode (default outside CI unless --no-interactive)",
|
|
2008
|
+
void 0
|
|
2009
|
+
).option(
|
|
2010
|
+
"--no-interactive",
|
|
2011
|
+
"disable interactive mode (use only flags / non-interactive flow)"
|
|
2012
|
+
).option("--list-templates", "list all available templates").option("--list-addons", "list all available addons").action((providedProjectName) => {
|
|
1998
2013
|
projectName = providedProjectName || projectName;
|
|
1999
2014
|
});
|
|
2000
2015
|
program.parse(process.argv);
|