create-awesome-node-app 0.8.0 → 0.9.0

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 CHANGED
@@ -101,8 +101,8 @@ create-awesome-node-app --template react-vite-boilerplate --list-addons
101
101
 
102
102
  ## 🧱 Template Ecosystem
103
103
 
104
- | Category | Example Templates |
105
- | ---------------- | ----------------------------------------------------------------- |
104
+ | Category | Example Templates |
105
+ | --------------- | ----------------------------------------------------------------- |
106
106
  | 🖥 Frontend | `react-vite-boilerplate` — React 18 + Vite + TS + ESLint + Vitest |
107
107
  | 🔧 Backend | `nestjs-boilerplate` — NestJS + TS + ESLint + Jest |
108
108
  | 🌐 Full Stack | `nextjs-starter` — Next.js + SSR + TS + Prettier |
@@ -118,8 +118,8 @@ create-awesome-node-app --template react-vite-boilerplate --list-addons
118
118
 
119
119
  Think of addons as _lego bricks_ — snap them onto any template to add exactly what you need:
120
120
 
121
- | Category | Examples |
122
- | --------------- | -------------------------------------------------------- |
121
+ | Category | Examples |
122
+ | -------------- | -------------------------------------------------------- |
123
123
  | 🎨 UI Libraries | Material UI, Tailwind CSS, component libraries |
124
124
  | 📊 State & Data | Jotai, tRPC, React Query, Zustand |
125
125
  | 🔧 Tooling | GitHub Actions workflows, changesets, release automation |
@@ -184,7 +184,7 @@ npm create awesome-node-app@latest my-app
184
184
 
185
185
  ## 🔍 CLI Reference
186
186
 
187
- ```
187
+ ```text
188
188
  Usage: create-awesome-node-app [project-directory] [options]
189
189
  ```
190
190
 
package/dist/index.cjs CHANGED
@@ -992,9 +992,9 @@ var require_color_convert = __commonJS({
992
992
  }
993
993
  });
994
994
 
995
- // node_modules/ansi-styles/index.js
995
+ // ../../node_modules/chalk/node_modules/ansi-styles/index.js
996
996
  var require_ansi_styles = __commonJS({
997
- "node_modules/ansi-styles/index.js"(exports2, module2) {
997
+ "../../node_modules/chalk/node_modules/ansi-styles/index.js"(exports2, module2) {
998
998
  "use strict";
999
999
  var wrapAnsi16 = (fn, offset) => (...args) => {
1000
1000
  const code = fn(...args);
@@ -1249,9 +1249,9 @@ var require_supports_color = __commonJS({
1249
1249
  }
1250
1250
  });
1251
1251
 
1252
- // node_modules/chalk/source/util.js
1252
+ // ../../node_modules/chalk/source/util.js
1253
1253
  var require_util = __commonJS({
1254
- "node_modules/chalk/source/util.js"(exports2, module2) {
1254
+ "../../node_modules/chalk/source/util.js"(exports2, module2) {
1255
1255
  "use strict";
1256
1256
  var stringReplaceAll = (string, substring, replacer) => {
1257
1257
  let index = string.indexOf(substring);
@@ -1288,9 +1288,9 @@ var require_util = __commonJS({
1288
1288
  }
1289
1289
  });
1290
1290
 
1291
- // node_modules/chalk/source/templates.js
1291
+ // ../../node_modules/chalk/source/templates.js
1292
1292
  var require_templates = __commonJS({
1293
- "node_modules/chalk/source/templates.js"(exports2, module2) {
1293
+ "../../node_modules/chalk/source/templates.js"(exports2, module2) {
1294
1294
  "use strict";
1295
1295
  var TEMPLATE_REGEX = /(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi;
1296
1296
  var STYLE_REGEX = /(?:^|\.)(\w+)(?:\(([^)]*)\))?/g;
@@ -1402,9 +1402,9 @@ var require_templates = __commonJS({
1402
1402
  }
1403
1403
  });
1404
1404
 
1405
- // node_modules/chalk/source/index.js
1405
+ // ../../node_modules/chalk/source/index.js
1406
1406
  var require_source = __commonJS({
1407
- "node_modules/chalk/source/index.js"(exports2, module2) {
1407
+ "../../node_modules/chalk/source/index.js"(exports2, module2) {
1408
1408
  "use strict";
1409
1409
  var ansiStyles = require_ansi_styles();
1410
1410
  var { stdout: stdoutColor, stderr: stderrColor } = require_supports_color();
@@ -1681,7 +1681,7 @@ var getExtensionsGroupedByCategory = async (type, cliArgs) => {
1681
1681
  };
1682
1682
 
1683
1683
  // src/options.ts
1684
- var PACKAGE_MANAGERS = ["npm", "yarn", "pnpm"];
1684
+ var PACKAGE_MANAGERS = ["npm", "yarn", "pnpm", "bun"];
1685
1685
  var isValidUrl = (url) => {
1686
1686
  try {
1687
1687
  new URL(url);
@@ -1963,10 +1963,41 @@ var getCnaOptions = async (options) => {
1963
1963
  return processNonInteractiveOptions(options);
1964
1964
  };
1965
1965
 
1966
+ // src/set-overrides.ts
1967
+ var unquoteSetValue = (value) => {
1968
+ if (value.startsWith('"') && value.endsWith('"') || value.startsWith("'") && value.endsWith("'")) {
1969
+ return value.slice(1, -1);
1970
+ }
1971
+ return value;
1972
+ };
1973
+ var parseSetOverrides = (set) => {
1974
+ const setOverrides = {};
1975
+ if (!Array.isArray(set)) {
1976
+ return setOverrides;
1977
+ }
1978
+ const assignments = [];
1979
+ for (const part of set) {
1980
+ if (part.includes("=") || assignments.length === 0) {
1981
+ assignments.push(part);
1982
+ } else {
1983
+ assignments[assignments.length - 1] += ` ${part}`;
1984
+ }
1985
+ }
1986
+ for (const assignment of assignments) {
1987
+ const eqIdx = assignment.indexOf("=");
1988
+ if (eqIdx > 0) {
1989
+ setOverrides[assignment.slice(0, eqIdx).trim()] = unquoteSetValue(
1990
+ assignment.slice(eqIdx + 1).trim()
1991
+ );
1992
+ }
1993
+ }
1994
+ return setOverrides;
1995
+ };
1996
+
1966
1997
  // package.json
1967
1998
  var package_default = {
1968
1999
  name: "create-awesome-node-app",
1969
- version: "0.8.0",
2000
+ version: "0.9.0",
1970
2001
  type: "module",
1971
2002
  description: "Command line tool to create Node apps with a lot of different templates and extensions.",
1972
2003
  license: "MIT",
@@ -2021,24 +2052,21 @@ var package_default = {
2021
2052
  },
2022
2053
  dependencies: {
2023
2054
  "@create-node-app/core": "^0.6.0",
2024
- axios: "^1.13.6",
2055
+ axios: "^1.16.0",
2025
2056
  "ci-info": "^4.3.0",
2026
- commander: "^14.0.1",
2057
+ commander: "^14.0.3",
2027
2058
  prompts: "^2.4.2",
2028
- semver: "^7.7.2"
2059
+ semver: "^7.7.4"
2029
2060
  },
2030
2061
  devDependencies: {
2031
2062
  "@create-node-app/core": "^0.6.0",
2032
- "@create-node-app/eslint-config-ts": "*",
2033
- "@types/node": "^24.5.2",
2063
+ "@types/node": "^26.0.1",
2034
2064
  "@types/prompts": "^2.4.9",
2035
2065
  "@types/semver": "^7.5.8",
2036
2066
  eslint: "^9.35.0",
2037
- "eslint-config-turbo": "^2.5.6",
2038
- "eslint-plugin-turbo": "^2.5.6",
2039
- nock: "^13.5.4",
2040
- tsup: "^8.5.0",
2041
- tsx: "^4.19.0"
2067
+ nock: "^14.0.15",
2068
+ tsup: "^8.5.1",
2069
+ tsx: "^4.22.4"
2042
2070
  }
2043
2071
  };
2044
2072
 
@@ -2131,7 +2159,7 @@ var main = async () => {
2131
2159
  ).option(
2132
2160
  "--addons [extensions...]",
2133
2161
  "specify extensions to apply for the boilerplate generation"
2134
- ).option("--use-yarn", "use yarn instead of npm or pnpm").option("--use-pnpm", "use pnpm instead of yarn or npm").option(
2162
+ ).option("--use-yarn", "use yarn instead of npm or pnpm or bun").option("--use-pnpm", "use pnpm instead of yarn, npm, or bun").option("--use-bun", "use bun instead of npm, yarn, or pnpm").option(
2135
2163
  "--interactive",
2136
2164
  "force interactive mode (default outside CI unless --no-interactive)",
2137
2165
  void 0
@@ -2140,7 +2168,7 @@ var main = async () => {
2140
2168
  "disable interactive mode (use only flags / non-interactive flow)"
2141
2169
  ).option("--list-templates", "list all available templates").option("--list-addons", "list all available addons").option(
2142
2170
  "--set <assignments...>",
2143
- "set a custom template option (format: key=value, repeatable)"
2171
+ "set a custom template option (format: key=value; quote values with spaces: --set 'projectName=My App' or --set 'projectName=My App' --set 'author=Jane Doe')"
2144
2172
  ).action((providedProjectName) => {
2145
2173
  projectName = providedProjectName || projectName;
2146
2174
  });
@@ -2169,19 +2197,9 @@ We recommend always using the latest version of create-awesome-node-app if possi
2169
2197
  });
2170
2198
  return;
2171
2199
  }
2172
- const { useYarn, usePnpm, set, ...restOpts } = opts;
2173
- const packageManager = useYarn ? "yarn" : usePnpm ? "pnpm" : "npm";
2174
- const setOverrides = {};
2175
- if (Array.isArray(set)) {
2176
- for (const assignment of set) {
2177
- const eqIdx = assignment.indexOf("=");
2178
- if (eqIdx > 0) {
2179
- setOverrides[assignment.slice(0, eqIdx).trim()] = assignment.slice(
2180
- eqIdx + 1
2181
- );
2182
- }
2183
- }
2184
- }
2200
+ const { useYarn, usePnpm, useBun, set, ...restOpts } = opts;
2201
+ const packageManager = useYarn ? "yarn" : usePnpm ? "pnpm" : useBun ? "bun" : "npm";
2202
+ const setOverrides = parseSetOverrides(set);
2185
2203
  const templatesOrExtensions = [restOpts.template].concat(Array.isArray(restOpts.extend) ? restOpts.extend : []).filter(Boolean).reduce((acc, templateOrExtension) => {
2186
2204
  if (!templateOrExtension) return acc;
2187
2205
  return acc.concat({ url: templateOrExtension });