create-cloudflare 0.0.0-7f60db2c → 0.0.0-811730d8

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 (35) hide show
  1. package/README.md +1 -1
  2. package/dist/cli.js +418 -136
  3. package/package.json +9 -5
  4. package/templates/chatgptPlugin/ts/README.md +2 -2
  5. package/templates/chatgptPlugin/ts/__dot__gitignore +171 -0
  6. package/templates/chatgptPlugin/ts/package.json +2 -1
  7. package/templates/chatgptPlugin/ts/src/search.ts +3 -7
  8. package/templates/common/js/__dot__gitignore +172 -0
  9. package/templates/common/js/package.json +1 -0
  10. package/templates/common/ts/__dot__gitignore +172 -0
  11. package/templates/common/ts/package.json +1 -0
  12. package/templates/hello-world/js/__dot__gitignore +172 -0
  13. package/templates/hello-world/js/package.json +1 -0
  14. package/templates/hello-world/ts/__dot__gitignore +172 -0
  15. package/templates/hello-world/ts/package.json +1 -0
  16. package/templates/openapi/ts/README.md +25 -0
  17. package/templates/openapi/ts/__dot__gitignore +171 -0
  18. package/templates/openapi/ts/package.json +19 -0
  19. package/templates/openapi/ts/src/endpoints/taskCreate.ts +48 -0
  20. package/templates/openapi/ts/src/endpoints/taskDelete.ts +55 -0
  21. package/templates/openapi/ts/src/endpoints/taskFetch.ts +74 -0
  22. package/templates/openapi/ts/src/endpoints/taskList.ts +66 -0
  23. package/templates/openapi/ts/src/index.ts +29 -0
  24. package/templates/openapi/ts/src/types.ts +9 -0
  25. package/templates/openapi/ts/tsconfig.json +32 -0
  26. package/templates/openapi/ts/wrangler.toml +3 -0
  27. package/templates/queues/js/__dot__gitignore +172 -0
  28. package/templates/queues/js/package.json +1 -0
  29. package/templates/queues/ts/__dot__gitignore +172 -0
  30. package/templates/queues/ts/package.json +1 -0
  31. package/templates/scheduled/js/__dot__gitignore +172 -0
  32. package/templates/scheduled/js/package.json +1 -0
  33. package/templates/scheduled/js/wrangler.toml +1 -1
  34. package/templates/scheduled/ts/__dot__gitignore +172 -0
  35. package/templates/scheduled/ts/package.json +1 -0
package/dist/cli.js CHANGED
@@ -1205,7 +1205,7 @@ var require_parse = __commonJS({
1205
1205
  }
1206
1206
  return parsed;
1207
1207
  }
1208
- function parse2(command2, args, options) {
1208
+ function parse3(command2, args, options) {
1209
1209
  if (args && !Array.isArray(args)) {
1210
1210
  options = args;
1211
1211
  args = null;
@@ -1224,7 +1224,7 @@ var require_parse = __commonJS({
1224
1224
  };
1225
1225
  return options.shell ? parsed : parseNonShell(parsed);
1226
1226
  }
1227
- module2.exports = parse2;
1227
+ module2.exports = parse3;
1228
1228
  }
1229
1229
  });
1230
1230
 
@@ -1283,16 +1283,16 @@ var require_cross_spawn = __commonJS({
1283
1283
  "../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/index.js"(exports, module2) {
1284
1284
  "use strict";
1285
1285
  var cp3 = require("child_process");
1286
- var parse2 = require_parse();
1286
+ var parse3 = require_parse();
1287
1287
  var enoent = require_enoent();
1288
1288
  function spawn2(command2, args, options) {
1289
- const parsed = parse2(command2, args, options);
1289
+ const parsed = parse3(command2, args, options);
1290
1290
  const spawned = cp3.spawn(parsed.command, parsed.args, parsed.options);
1291
1291
  enoent.hookChildProcess(spawned, parsed);
1292
1292
  return spawned;
1293
1293
  }
1294
1294
  function spawnSync(command2, args, options) {
1295
- const parsed = parse2(command2, args, options);
1295
+ const parsed = parse3(command2, args, options);
1296
1296
  const result = cp3.spawnSync(parsed.command, parsed.args, parsed.options);
1297
1297
  result.error = result.error || enoent.verifyENOENTSync(result.status, parsed);
1298
1298
  return result;
@@ -1300,7 +1300,7 @@ var require_cross_spawn = __commonJS({
1300
1300
  module2.exports = spawn2;
1301
1301
  module2.exports.spawn = spawn2;
1302
1302
  module2.exports.sync = spawnSync;
1303
- module2.exports._parse = parse2;
1303
+ module2.exports._parse = parse3;
1304
1304
  module2.exports._enoent = enoent;
1305
1305
  }
1306
1306
  });
@@ -2143,7 +2143,7 @@ var require_semver = __commonJS({
2143
2143
  var require_parse2 = __commonJS({
2144
2144
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/parse.js"(exports, module2) {
2145
2145
  var SemVer = require_semver();
2146
- var parse2 = (version3, options, throwErrors = false) => {
2146
+ var parse3 = (version3, options, throwErrors = false) => {
2147
2147
  if (version3 instanceof SemVer) {
2148
2148
  return version3;
2149
2149
  }
@@ -2156,16 +2156,16 @@ var require_parse2 = __commonJS({
2156
2156
  throw er;
2157
2157
  }
2158
2158
  };
2159
- module2.exports = parse2;
2159
+ module2.exports = parse3;
2160
2160
  }
2161
2161
  });
2162
2162
 
2163
2163
  // ../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/valid.js
2164
2164
  var require_valid = __commonJS({
2165
2165
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/valid.js"(exports, module2) {
2166
- var parse2 = require_parse2();
2166
+ var parse3 = require_parse2();
2167
2167
  var valid = (version3, options) => {
2168
- const v2 = parse2(version3, options);
2168
+ const v2 = parse3(version3, options);
2169
2169
  return v2 ? v2.version : null;
2170
2170
  };
2171
2171
  module2.exports = valid;
@@ -2175,9 +2175,9 @@ var require_valid = __commonJS({
2175
2175
  // ../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/clean.js
2176
2176
  var require_clean = __commonJS({
2177
2177
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/clean.js"(exports, module2) {
2178
- var parse2 = require_parse2();
2178
+ var parse3 = require_parse2();
2179
2179
  var clean = (version3, options) => {
2180
- const s = parse2(version3.trim().replace(/^[=v]+/, ""), options);
2180
+ const s = parse3(version3.trim().replace(/^[=v]+/, ""), options);
2181
2181
  return s ? s.version : null;
2182
2182
  };
2183
2183
  module2.exports = clean;
@@ -2210,10 +2210,10 @@ var require_inc = __commonJS({
2210
2210
  // ../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/diff.js
2211
2211
  var require_diff = __commonJS({
2212
2212
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/diff.js"(exports, module2) {
2213
- var parse2 = require_parse2();
2213
+ var parse3 = require_parse2();
2214
2214
  var diff = (version1, version22) => {
2215
- const v1 = parse2(version1, null, true);
2216
- const v2 = parse2(version22, null, true);
2215
+ const v1 = parse3(version1, null, true);
2216
+ const v2 = parse3(version22, null, true);
2217
2217
  const comparison = v1.compare(v2);
2218
2218
  if (comparison === 0) {
2219
2219
  return null;
@@ -2277,9 +2277,9 @@ var require_patch = __commonJS({
2277
2277
  // ../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/prerelease.js
2278
2278
  var require_prerelease = __commonJS({
2279
2279
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/prerelease.js"(exports, module2) {
2280
- var parse2 = require_parse2();
2280
+ var parse3 = require_parse2();
2281
2281
  var prerelease = (version3, options) => {
2282
- const parsed = parse2(version3, options);
2282
+ const parsed = parse3(version3, options);
2283
2283
  return parsed && parsed.prerelease.length ? parsed.prerelease : null;
2284
2284
  };
2285
2285
  module2.exports = prerelease;
@@ -2451,7 +2451,7 @@ var require_cmp = __commonJS({
2451
2451
  var require_coerce = __commonJS({
2452
2452
  "../../node_modules/.pnpm/semver@7.5.1/node_modules/semver/functions/coerce.js"(exports, module2) {
2453
2453
  var SemVer = require_semver();
2454
- var parse2 = require_parse2();
2454
+ var parse3 = require_parse2();
2455
2455
  var { re, t } = require_re();
2456
2456
  var coerce = (version3, options) => {
2457
2457
  if (version3 instanceof SemVer) {
@@ -2480,7 +2480,7 @@ var require_coerce = __commonJS({
2480
2480
  if (match === null) {
2481
2481
  return null;
2482
2482
  }
2483
- return parse2(`${match[2]}.${match[3] || "0"}.${match[4] || "0"}`, options);
2483
+ return parse3(`${match[2]}.${match[3] || "0"}.${match[4] || "0"}`, options);
2484
2484
  };
2485
2485
  module2.exports = coerce;
2486
2486
  }
@@ -4080,7 +4080,7 @@ var require_semver2 = __commonJS({
4080
4080
  var constants = require_constants();
4081
4081
  var SemVer = require_semver();
4082
4082
  var identifiers = require_identifiers();
4083
- var parse2 = require_parse2();
4083
+ var parse3 = require_parse2();
4084
4084
  var valid = require_valid();
4085
4085
  var clean = require_clean();
4086
4086
  var inc = require_inc();
@@ -4118,7 +4118,7 @@ var require_semver2 = __commonJS({
4118
4118
  var simplifyRange = require_simplify();
4119
4119
  var subset = require_subset();
4120
4120
  module2.exports = {
4121
- parse: parse2,
4121
+ parse: parse3,
4122
4122
  valid,
4123
4123
  clean,
4124
4124
  inc,
@@ -4189,6 +4189,233 @@ var require_which_pm_runs = __commonJS({
4189
4189
  }
4190
4190
  });
4191
4191
 
4192
+ // ../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/quote.js
4193
+ var require_quote = __commonJS({
4194
+ "../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/quote.js"(exports, module2) {
4195
+ "use strict";
4196
+ module2.exports = function quote2(xs) {
4197
+ return xs.map(function(s) {
4198
+ if (s && typeof s === "object") {
4199
+ return s.op.replace(/(.)/g, "\\$1");
4200
+ }
4201
+ if (/["\s]/.test(s) && !/'/.test(s)) {
4202
+ return "'" + s.replace(/(['\\])/g, "\\$1") + "'";
4203
+ }
4204
+ if (/["'\s]/.test(s)) {
4205
+ return '"' + s.replace(/(["\\$`!])/g, "\\$1") + '"';
4206
+ }
4207
+ return String(s).replace(/([A-Za-z]:)?([#!"$&'()*,:;<=>?@[\\\]^`{|}])/g, "$1\\$2");
4208
+ }).join(" ");
4209
+ };
4210
+ }
4211
+ });
4212
+
4213
+ // ../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/parse.js
4214
+ var require_parse3 = __commonJS({
4215
+ "../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/parse.js"(exports, module2) {
4216
+ "use strict";
4217
+ var CONTROL = "(?:" + [
4218
+ "\\|\\|",
4219
+ "\\&\\&",
4220
+ ";;",
4221
+ "\\|\\&",
4222
+ "\\<\\(",
4223
+ "\\<\\<\\<",
4224
+ ">>",
4225
+ ">\\&",
4226
+ "<\\&",
4227
+ "[&;()|<>]"
4228
+ ].join("|") + ")";
4229
+ var controlRE = new RegExp("^" + CONTROL + "$");
4230
+ var META = "|&;()<> \\t";
4231
+ var SINGLE_QUOTE = '"((\\\\"|[^"])*?)"';
4232
+ var DOUBLE_QUOTE = "'((\\\\'|[^'])*?)'";
4233
+ var hash = /^#$/;
4234
+ var SQ = "'";
4235
+ var DQ = '"';
4236
+ var DS = "$";
4237
+ var TOKEN = "";
4238
+ var mult = 4294967296;
4239
+ for (i = 0; i < 4; i++) {
4240
+ TOKEN += (mult * Math.random()).toString(16);
4241
+ }
4242
+ var i;
4243
+ var startsWithToken = new RegExp("^" + TOKEN);
4244
+ function matchAll(s, r2) {
4245
+ var origIndex = r2.lastIndex;
4246
+ var matches = [];
4247
+ var matchObj;
4248
+ while (matchObj = r2.exec(s)) {
4249
+ matches.push(matchObj);
4250
+ if (r2.lastIndex === matchObj.index) {
4251
+ r2.lastIndex += 1;
4252
+ }
4253
+ }
4254
+ r2.lastIndex = origIndex;
4255
+ return matches;
4256
+ }
4257
+ function getVar(env3, pre, key) {
4258
+ var r2 = typeof env3 === "function" ? env3(key) : env3[key];
4259
+ if (typeof r2 === "undefined" && key != "") {
4260
+ r2 = "";
4261
+ } else if (typeof r2 === "undefined") {
4262
+ r2 = "$";
4263
+ }
4264
+ if (typeof r2 === "object") {
4265
+ return pre + TOKEN + JSON.stringify(r2) + TOKEN;
4266
+ }
4267
+ return pre + r2;
4268
+ }
4269
+ function parseInternal(string, env3, opts) {
4270
+ if (!opts) {
4271
+ opts = {};
4272
+ }
4273
+ var BS = opts.escape || "\\";
4274
+ var BAREWORD = "(\\" + BS + `['"` + META + `]|[^\\s'"` + META + "])+";
4275
+ var chunker = new RegExp([
4276
+ "(" + CONTROL + ")",
4277
+ // control chars
4278
+ "(" + BAREWORD + "|" + SINGLE_QUOTE + "|" + DOUBLE_QUOTE + ")+"
4279
+ ].join("|"), "g");
4280
+ var matches = matchAll(string, chunker);
4281
+ if (matches.length === 0) {
4282
+ return [];
4283
+ }
4284
+ if (!env3) {
4285
+ env3 = {};
4286
+ }
4287
+ var commented = false;
4288
+ return matches.map(function(match) {
4289
+ var s = match[0];
4290
+ if (!s || commented) {
4291
+ return void 0;
4292
+ }
4293
+ if (controlRE.test(s)) {
4294
+ return { op: s };
4295
+ }
4296
+ var quote2 = false;
4297
+ var esc = false;
4298
+ var out = "";
4299
+ var isGlob = false;
4300
+ var i2;
4301
+ function parseEnvVar() {
4302
+ i2 += 1;
4303
+ var varend;
4304
+ var varname;
4305
+ var char = s.charAt(i2);
4306
+ if (char === "{") {
4307
+ i2 += 1;
4308
+ if (s.charAt(i2) === "}") {
4309
+ throw new Error("Bad substitution: " + s.slice(i2 - 2, i2 + 1));
4310
+ }
4311
+ varend = s.indexOf("}", i2);
4312
+ if (varend < 0) {
4313
+ throw new Error("Bad substitution: " + s.slice(i2));
4314
+ }
4315
+ varname = s.slice(i2, varend);
4316
+ i2 = varend;
4317
+ } else if (/[*@#?$!_-]/.test(char)) {
4318
+ varname = char;
4319
+ i2 += 1;
4320
+ } else {
4321
+ var slicedFromI = s.slice(i2);
4322
+ varend = slicedFromI.match(/[^\w\d_]/);
4323
+ if (!varend) {
4324
+ varname = slicedFromI;
4325
+ i2 = s.length;
4326
+ } else {
4327
+ varname = slicedFromI.slice(0, varend.index);
4328
+ i2 += varend.index - 1;
4329
+ }
4330
+ }
4331
+ return getVar(env3, "", varname);
4332
+ }
4333
+ for (i2 = 0; i2 < s.length; i2++) {
4334
+ var c2 = s.charAt(i2);
4335
+ isGlob = isGlob || !quote2 && (c2 === "*" || c2 === "?");
4336
+ if (esc) {
4337
+ out += c2;
4338
+ esc = false;
4339
+ } else if (quote2) {
4340
+ if (c2 === quote2) {
4341
+ quote2 = false;
4342
+ } else if (quote2 == SQ) {
4343
+ out += c2;
4344
+ } else {
4345
+ if (c2 === BS) {
4346
+ i2 += 1;
4347
+ c2 = s.charAt(i2);
4348
+ if (c2 === DQ || c2 === BS || c2 === DS) {
4349
+ out += c2;
4350
+ } else {
4351
+ out += BS + c2;
4352
+ }
4353
+ } else if (c2 === DS) {
4354
+ out += parseEnvVar();
4355
+ } else {
4356
+ out += c2;
4357
+ }
4358
+ }
4359
+ } else if (c2 === DQ || c2 === SQ) {
4360
+ quote2 = c2;
4361
+ } else if (controlRE.test(c2)) {
4362
+ return { op: s };
4363
+ } else if (hash.test(c2)) {
4364
+ commented = true;
4365
+ var commentObj = { comment: string.slice(match.index + i2 + 1) };
4366
+ if (out.length) {
4367
+ return [out, commentObj];
4368
+ }
4369
+ return [commentObj];
4370
+ } else if (c2 === BS) {
4371
+ esc = true;
4372
+ } else if (c2 === DS) {
4373
+ out += parseEnvVar();
4374
+ } else {
4375
+ out += c2;
4376
+ }
4377
+ }
4378
+ if (isGlob) {
4379
+ return { op: "glob", pattern: out };
4380
+ }
4381
+ return out;
4382
+ }).reduce(function(prev, arg) {
4383
+ return typeof arg === "undefined" ? prev : prev.concat(arg);
4384
+ }, []);
4385
+ }
4386
+ module2.exports = function parse3(s, env3, opts) {
4387
+ var mapped = parseInternal(s, env3, opts);
4388
+ if (typeof env3 !== "function") {
4389
+ return mapped;
4390
+ }
4391
+ return mapped.reduce(function(acc, s2) {
4392
+ if (typeof s2 === "object") {
4393
+ return acc.concat(s2);
4394
+ }
4395
+ var xs = s2.split(RegExp("(" + TOKEN + ".*?" + TOKEN + ")", "g"));
4396
+ if (xs.length === 1) {
4397
+ return acc.concat(xs[0]);
4398
+ }
4399
+ return acc.concat(xs.filter(Boolean).map(function(x2) {
4400
+ if (startsWithToken.test(x2)) {
4401
+ return JSON.parse(x2.split(TOKEN)[1]);
4402
+ }
4403
+ return x2;
4404
+ }));
4405
+ }, []);
4406
+ };
4407
+ }
4408
+ });
4409
+
4410
+ // ../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/index.js
4411
+ var require_shell_quote = __commonJS({
4412
+ "../../node_modules/.pnpm/shell-quote@1.8.1/node_modules/shell-quote/index.js"(exports) {
4413
+ "use strict";
4414
+ exports.quote = require_quote();
4415
+ exports.parse = require_parse3();
4416
+ }
4417
+ });
4418
+
4192
4419
  // ../../node_modules/.pnpm/tslib@2.5.3/node_modules/tslib/tslib.es6.mjs
4193
4420
  var tslib_es6_exports = {};
4194
4421
  __export(tslib_es6_exports, {
@@ -10102,7 +10329,7 @@ var require_esprima2 = __commonJS({
10102
10329
  var jsx_parser_1 = __webpack_require__(3);
10103
10330
  var parser_1 = __webpack_require__(8);
10104
10331
  var tokenizer_1 = __webpack_require__(15);
10105
- function parse2(code, options, delegate) {
10332
+ function parse3(code, options, delegate) {
10106
10333
  var commentHandler = null;
10107
10334
  var proxyDelegate = function(node, metadata) {
10108
10335
  if (delegate) {
@@ -10147,17 +10374,17 @@ var require_esprima2 = __commonJS({
10147
10374
  }
10148
10375
  return ast;
10149
10376
  }
10150
- exports2.parse = parse2;
10377
+ exports2.parse = parse3;
10151
10378
  function parseModule(code, options, delegate) {
10152
10379
  var parsingOptions = options || {};
10153
10380
  parsingOptions.sourceType = "module";
10154
- return parse2(code, parsingOptions, delegate);
10381
+ return parse3(code, parsingOptions, delegate);
10155
10382
  }
10156
10383
  exports2.parseModule = parseModule;
10157
10384
  function parseScript(code, options, delegate) {
10158
10385
  var parsingOptions = options || {};
10159
10386
  parsingOptions.sourceType = "script";
10160
- return parse2(code, parsingOptions, delegate);
10387
+ return parse3(code, parsingOptions, delegate);
10161
10388
  }
10162
10389
  exports2.parseScript = parseScript;
10163
10390
  function tokenize(code, options, delegate) {
@@ -10504,7 +10731,7 @@ var require_esprima2 = __commonJS({
10504
10731
  column: this.scanner.index - this.scanner.lineStart
10505
10732
  };
10506
10733
  };
10507
- JSXParser2.prototype.scanXHTMLEntity = function(quote) {
10734
+ JSXParser2.prototype.scanXHTMLEntity = function(quote2) {
10508
10735
  var result = "&";
10509
10736
  var valid = true;
10510
10737
  var terminated = false;
@@ -10512,7 +10739,7 @@ var require_esprima2 = __commonJS({
10512
10739
  var hex = false;
10513
10740
  while (!this.scanner.eof() && valid && !terminated) {
10514
10741
  var ch = this.scanner.source[this.scanner.index];
10515
- if (ch === quote) {
10742
+ if (ch === quote2) {
10516
10743
  break;
10517
10744
  }
10518
10745
  terminated = ch === ";";
@@ -10564,14 +10791,14 @@ var require_esprima2 = __commonJS({
10564
10791
  }
10565
10792
  if (cp3 === 34 || cp3 === 39) {
10566
10793
  var start = this.scanner.index;
10567
- var quote = this.scanner.source[this.scanner.index++];
10794
+ var quote2 = this.scanner.source[this.scanner.index++];
10568
10795
  var str = "";
10569
10796
  while (!this.scanner.eof()) {
10570
10797
  var ch = this.scanner.source[this.scanner.index++];
10571
- if (ch === quote) {
10798
+ if (ch === quote2) {
10572
10799
  break;
10573
10800
  } else if (ch === "&") {
10574
- str += this.scanXHTMLEntity(quote);
10801
+ str += this.scanXHTMLEntity(quote2);
10575
10802
  } else {
10576
10803
  str += ch;
10577
10804
  }
@@ -15418,15 +15645,15 @@ var require_esprima2 = __commonJS({
15418
15645
  };
15419
15646
  Scanner2.prototype.scanStringLiteral = function() {
15420
15647
  var start = this.index;
15421
- var quote = this.source[start];
15422
- assert_1.assert(quote === "'" || quote === '"', "String literal must starts with a quote");
15648
+ var quote2 = this.source[start];
15649
+ assert_1.assert(quote2 === "'" || quote2 === '"', "String literal must starts with a quote");
15423
15650
  ++this.index;
15424
15651
  var octal = false;
15425
15652
  var str = "";
15426
15653
  while (!this.eof()) {
15427
15654
  var ch = this.source[this.index++];
15428
- if (ch === quote) {
15429
- quote = "";
15655
+ if (ch === quote2) {
15656
+ quote2 = "";
15430
15657
  break;
15431
15658
  } else if (ch === "\\") {
15432
15659
  ch = this.source[this.index++];
@@ -15497,7 +15724,7 @@ var require_esprima2 = __commonJS({
15497
15724
  str += ch;
15498
15725
  }
15499
15726
  }
15500
- if (quote !== "") {
15727
+ if (quote2 !== "") {
15501
15728
  this.index = start;
15502
15729
  this.throwUnexpectedToken();
15503
15730
  }
@@ -16298,7 +16525,7 @@ var require_esprima3 = __commonJS({
16298
16525
  Object.defineProperty(exports, "__esModule", { value: true });
16299
16526
  exports.parse = void 0;
16300
16527
  var util_1 = require_util2();
16301
- function parse2(source, options) {
16528
+ function parse3(source, options) {
16302
16529
  var comments = [];
16303
16530
  var ast = require_esprima2().parse(source, {
16304
16531
  loc: true,
@@ -16316,7 +16543,7 @@ var require_esprima3 = __commonJS({
16316
16543
  }
16317
16544
  return ast;
16318
16545
  }
16319
- exports.parse = parse2;
16546
+ exports.parse = parse3;
16320
16547
  }
16321
16548
  });
16322
16549
 
@@ -17450,7 +17677,7 @@ var require_parser = __commonJS({
17450
17677
  var lines_1 = require_lines();
17451
17678
  var comments_1 = require_comments();
17452
17679
  var util = tslib_1.__importStar(require_util2());
17453
- function parse2(source, options) {
17680
+ function parse3(source, options) {
17454
17681
  options = options_1.normalize(options);
17455
17682
  var lines = lines_1.fromString(source, options);
17456
17683
  var sourceWithoutTabs = lines.toString({
@@ -17522,7 +17749,7 @@ var require_parser = __commonJS({
17522
17749
  comments_1.attach(comments, program.body.length ? file.program : file, lines);
17523
17750
  return new TreeCopier(lines, tokens).copy(file);
17524
17751
  }
17525
- exports.parse = parse2;
17752
+ exports.parse = parse3;
17526
17753
  var TreeCopier = function TreeCopier2(lines, tokens) {
17527
17754
  assert_1.default.ok(this instanceof TreeCopier2);
17528
17755
  this.lines = lines;
@@ -23784,13 +24011,13 @@ var require_lib = __commonJS({
23784
24011
  this.state.pos = pos;
23785
24012
  return code;
23786
24013
  }
23787
- readString(quote) {
24014
+ readString(quote2) {
23788
24015
  const {
23789
24016
  str,
23790
24017
  pos,
23791
24018
  curLine,
23792
24019
  lineStart
23793
- } = readStringContents(quote === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string);
24020
+ } = readStringContents(quote2 === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string);
23794
24021
  this.state.pos = pos + 1;
23795
24022
  this.state.lineStart = lineStart;
23796
24023
  this.state.curLine = curLine;
@@ -25944,14 +26171,14 @@ var require_lib = __commonJS({
25944
26171
  super.checkParams(node, false, true);
25945
26172
  this.scope.exit();
25946
26173
  }
25947
- forwardNoArrowParamsConversionAt(node, parse3) {
26174
+ forwardNoArrowParamsConversionAt(node, parse4) {
25948
26175
  let result;
25949
26176
  if (this.state.noArrowParamsConversionAt.indexOf(node.start) !== -1) {
25950
26177
  this.state.noArrowParamsConversionAt.push(this.state.start);
25951
- result = parse3();
26178
+ result = parse4();
25952
26179
  this.state.noArrowParamsConversionAt.pop();
25953
26180
  } else {
25954
- result = parse3();
26181
+ result = parse4();
25955
26182
  }
25956
26183
  return result;
25957
26184
  }
@@ -27373,7 +27600,7 @@ var require_lib = __commonJS({
27373
27600
  this.state.lineStart = this.state.pos;
27374
27601
  return out;
27375
27602
  }
27376
- jsxReadString(quote) {
27603
+ jsxReadString(quote2) {
27377
27604
  let out = "";
27378
27605
  let chunkStart = ++this.state.pos;
27379
27606
  for (; ; ) {
@@ -27383,7 +27610,7 @@ var require_lib = __commonJS({
27383
27610
  });
27384
27611
  }
27385
27612
  const ch = this.input.charCodeAt(this.state.pos);
27386
- if (ch === quote)
27613
+ if (ch === quote2)
27387
27614
  break;
27388
27615
  if (ch === 38) {
27389
27616
  out += this.input.slice(chunkStart, this.state.pos);
@@ -35119,7 +35346,7 @@ var require_lib = __commonJS({
35119
35346
  }
35120
35347
  return pluginMap;
35121
35348
  }
35122
- function parse2(input, options) {
35349
+ function parse3(input, options) {
35123
35350
  var _options;
35124
35351
  if (((_options = options) == null ? void 0 : _options.sourceType) === "unambiguous") {
35125
35352
  options = Object.assign({}, options);
@@ -35189,7 +35416,7 @@ var require_lib = __commonJS({
35189
35416
  }
35190
35417
  return cls;
35191
35418
  }
35192
- exports.parse = parse2;
35419
+ exports.parse = parse3;
35193
35420
  exports.parseExpression = parseExpression;
35194
35421
  exports.tokTypes = tokTypes;
35195
35422
  }
@@ -35214,12 +35441,12 @@ var require_babel2 = __commonJS({
35214
35441
  }
35215
35442
  }
35216
35443
  }();
35217
- function parse2(source, options) {
35444
+ function parse3(source, options) {
35218
35445
  var babelOptions = _babel_options_1.default(options);
35219
35446
  babelOptions.plugins.push("jsx", "flow");
35220
35447
  return exports.parser.parse(source, babelOptions);
35221
35448
  }
35222
- exports.parse = parse2;
35449
+ exports.parse = parse3;
35223
35450
  }
35224
35451
  });
35225
35452
 
@@ -35232,12 +35459,12 @@ var require_typescript2 = __commonJS({
35232
35459
  var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
35233
35460
  var babel_1 = require_babel2();
35234
35461
  var _babel_options_1 = tslib_1.__importDefault(require_babel_options());
35235
- function parse2(source, options) {
35462
+ function parse3(source, options) {
35236
35463
  var babelOptions = _babel_options_1.default(options);
35237
35464
  babelOptions.plugins.push("typescript");
35238
35465
  return babel_1.parser.parse(source, babelOptions);
35239
35466
  }
35240
- exports.parse = parse2;
35467
+ exports.parse = parse3;
35241
35468
  }
35242
35469
  });
35243
35470
 
@@ -51408,7 +51635,7 @@ var require_util6 = __commonJS({
51408
51635
  });
51409
51636
 
51410
51637
  // ../../node_modules/.pnpm/undici@5.20.0/node_modules/undici/lib/cookies/parse.js
51411
- var require_parse3 = __commonJS({
51638
+ var require_parse4 = __commonJS({
51412
51639
  "../../node_modules/.pnpm/undici@5.20.0/node_modules/undici/lib/cookies/parse.js"(exports, module2) {
51413
51640
  "use strict";
51414
51641
  var { maxNameValuePairSize, maxAttributeValueSize } = require_constants4();
@@ -51551,7 +51778,7 @@ var require_parse3 = __commonJS({
51551
51778
  var require_cookies = __commonJS({
51552
51779
  "../../node_modules/.pnpm/undici@5.20.0/node_modules/undici/lib/cookies/index.js"(exports, module2) {
51553
51780
  "use strict";
51554
- var { parseSetCookie } = require_parse3();
51781
+ var { parseSetCookie } = require_parse4();
51555
51782
  var { stringify, getHeadersList } = require_util6();
51556
51783
  var { webidl } = require_webidl();
51557
51784
  var { Headers } = require_headers();
@@ -56856,9 +57083,9 @@ var YargsInstance = class {
56856
57083
  __classPrivateFieldSet(this, _YargsInstance_hasOutput, true, "f");
56857
57084
  if (!__classPrivateFieldGet(this, _YargsInstance_usage, "f").hasCachedHelpMessage()) {
56858
57085
  if (!this.parsed) {
56859
- const parse2 = this[kRunYargsParserAndExecuteCommands](__classPrivateFieldGet(this, _YargsInstance_processArgs, "f"), void 0, void 0, 0, true);
56860
- if (isPromise(parse2)) {
56861
- return parse2.then(() => {
57086
+ const parse3 = this[kRunYargsParserAndExecuteCommands](__classPrivateFieldGet(this, _YargsInstance_processArgs, "f"), void 0, void 0, 0, true);
57087
+ if (isPromise(parse3)) {
57088
+ return parse3.then(() => {
56862
57089
  return __classPrivateFieldGet(this, _YargsInstance_usage, "f").help();
56863
57090
  });
56864
57091
  }
@@ -57202,9 +57429,9 @@ var YargsInstance = class {
57202
57429
  __classPrivateFieldSet(this, _YargsInstance_hasOutput, true, "f");
57203
57430
  if (!__classPrivateFieldGet(this, _YargsInstance_usage, "f").hasCachedHelpMessage()) {
57204
57431
  if (!this.parsed) {
57205
- const parse2 = this[kRunYargsParserAndExecuteCommands](__classPrivateFieldGet(this, _YargsInstance_processArgs, "f"), void 0, void 0, 0, true);
57206
- if (isPromise(parse2)) {
57207
- parse2.then(() => {
57432
+ const parse3 = this[kRunYargsParserAndExecuteCommands](__classPrivateFieldGet(this, _YargsInstance_processArgs, "f"), void 0, void 0, 0, true);
57433
+ if (isPromise(parse3)) {
57434
+ parse3.then(() => {
57208
57435
  __classPrivateFieldGet(this, _YargsInstance_usage, "f").showHelp(level);
57209
57436
  });
57210
57437
  return this;
@@ -57864,10 +58091,11 @@ var Yargs = YargsFactory(esm_default);
57864
58091
  var yargs_default = Yargs;
57865
58092
 
57866
58093
  // package.json
57867
- var version = "0.0.0-7f60db2c";
58094
+ var version = "0.0.0-811730d8";
57868
58095
  var devDependencies = {
57869
58096
  "@babel/parser": "^7.21.3",
57870
58097
  "@babel/types": "^7.21.4",
58098
+ "@clack/core": "^0.3.2",
57871
58099
  "@clack/prompts": "^0.6.3",
57872
58100
  "@cloudflare/eslint-config-worker": "*",
57873
58101
  "@cloudflare/workers-tsconfig": "workspace:*",
@@ -57877,6 +58105,8 @@ var devDependencies = {
57877
58105
  "@types/dns2": "^2.0.3",
57878
58106
  "@types/esprima": "^4.0.3",
57879
58107
  "@types/node": "^18.15.3",
58108
+ "@types/semver": "^7.5.1",
58109
+ "@types/shell-quote": "^1.7.2",
57880
58110
  "@types/which-pm-runs": "^1.0.0",
57881
58111
  "@types/yargs": "^17.0.22",
57882
58112
  "@typescript-eslint/eslint-plugin": "^5.55.0",
@@ -57887,12 +58117,14 @@ var devDependencies = {
57887
58117
  dns2: "^2.1.0",
57888
58118
  esbuild: "^0.17.12",
57889
58119
  execa: "^7.1.1",
58120
+ glob: "^10.3.3",
57890
58121
  haikunator: "^2.1.2",
57891
58122
  "log-update": "^5.0.1",
57892
58123
  open: "^8.4.0",
57893
58124
  pnpm: "^8.6.11",
57894
58125
  recast: "^0.22.0",
57895
58126
  semver: "^7.5.1",
58127
+ "shell-quote": "^1.8.1",
57896
58128
  typescript: "^5.0.2",
57897
58129
  undici: "5.20.0",
57898
58130
  "vite-tsconfig-paths": "^4.0.8",
@@ -57900,9 +58132,7 @@ var devDependencies = {
57900
58132
  "which-pm-runs": "^1.1.0",
57901
58133
  wrangler: "workspace:*",
57902
58134
  yargs: "^17.7.1",
57903
- yarn: "^1.22.19",
57904
- "@clack/core": "^0.3.2",
57905
- "@types/semver": "^7.5.1"
58135
+ yarn: "^1.22.19"
57906
58136
  };
57907
58137
 
57908
58138
  // src/pages.ts
@@ -58504,7 +58734,7 @@ async function openInBrowser(url) {
58504
58734
  }
58505
58735
  var C3_DEFAULTS = {
58506
58736
  projectName: new import_haikunator.default().haikunate({ tokenHex: true }),
58507
- type: "hello-world",
58737
+ type: "webFramework",
58508
58738
  framework: "angular",
58509
58739
  autoUpdate: true,
58510
58740
  deploy: true,
@@ -59871,14 +60101,21 @@ var detectPackageManager = () => {
59871
60101
  case "pnpm":
59872
60102
  name2 = "pnpm";
59873
60103
  version3 = devDependencies["pnpm"].replace("^", "");
60104
+ process.env.npm_config_user_agent = "pnpm";
59874
60105
  break;
59875
60106
  case "yarn":
59876
60107
  name2 = "yarn";
59877
60108
  version3 = devDependencies["yarn"].replace("^", "");
60109
+ process.env.npm_config_user_agent = "yarn";
60110
+ break;
60111
+ case "bun":
60112
+ name2 = "bun";
60113
+ version3 = "1.0.0";
59878
60114
  break;
59879
60115
  case "npm":
59880
60116
  name2 = "npm";
59881
60117
  version3 = "0.0.0";
60118
+ process.env.npm_config_user_agent = "npm";
59882
60119
  break;
59883
60120
  }
59884
60121
  }
@@ -59917,6 +60154,14 @@ var detectPackageManager = () => {
59917
60154
  npx: "yarn",
59918
60155
  dlx: "yarn"
59919
60156
  };
60157
+ case "bun":
60158
+ return {
60159
+ name: name2,
60160
+ version: version3,
60161
+ npm: "bun",
60162
+ npx: "bunx",
60163
+ dlx: "bunx"
60164
+ };
59920
60165
  case "npm":
59921
60166
  default:
59922
60167
  return {
@@ -59929,14 +60174,39 @@ var detectPackageManager = () => {
59929
60174
  }
59930
60175
  };
59931
60176
 
60177
+ // src/helpers/shell-quote.ts
60178
+ var import_shell_quote = __toESM(require_shell_quote());
60179
+ var quote = import_shell_quote.default.quote;
60180
+ function parse(cmd, env3) {
60181
+ const entries = import_shell_quote.default.parse(cmd, env3);
60182
+ const argv = [];
60183
+ for (const entry of entries) {
60184
+ if (typeof entry === "string") {
60185
+ argv.push(entry);
60186
+ continue;
60187
+ }
60188
+ if ("comment" in entry) {
60189
+ continue;
60190
+ }
60191
+ if (entry.op === "glob") {
60192
+ argv.push(entry.pattern);
60193
+ continue;
60194
+ }
60195
+ throw new Error(
60196
+ `Only simple commands are supported, please don't use the "${entry.op}" operator in "${cmd}".`
60197
+ );
60198
+ }
60199
+ return argv;
60200
+ }
60201
+
59932
60202
  // src/helpers/command.ts
59933
60203
  var runCommand = async (command2, opts = {}) => {
59934
60204
  if (typeof command2 === "string") {
59935
- command2 = command2.trim().replace(/\s+/g, " ").split(" ");
60205
+ command2 = parse(command2);
59936
60206
  }
59937
60207
  return printAsyncStatus({
59938
60208
  useSpinner: opts.useSpinner ?? opts.silent,
59939
- startText: opts.startText || command2.join(" ").trim(),
60209
+ startText: opts.startText || quote(command2),
59940
60210
  doneText: opts.doneText,
59941
60211
  promise() {
59942
60212
  const [executable, ...args] = command2;
@@ -60034,7 +60304,7 @@ var retry = async (times, fn) => {
60034
60304
  };
60035
60305
  var runFrameworkGenerator = async (ctx, cmd) => {
60036
60306
  if (ctx.framework?.args?.length) {
60037
- cmd = `${cmd} ${ctx.framework.args.join(" ")}`;
60307
+ cmd = `${cmd} ${quote(ctx.framework.args)}`;
60038
60308
  }
60039
60309
  endSection(
60040
60310
  `Continue with ${ctx.framework?.config.displayName}`,
@@ -60042,19 +60312,23 @@ var runFrameworkGenerator = async (ctx, cmd) => {
60042
60312
  );
60043
60313
  if (process.env.VITEST) {
60044
60314
  const flags = ctx.framework?.config.testFlags ?? [];
60045
- cmd = `${cmd} ${flags.join(" ")}`;
60315
+ cmd = `${cmd} ${quote(flags)}`;
60046
60316
  }
60047
60317
  await runCommand(cmd);
60048
60318
  };
60049
60319
  var installPackages = async (packages, config14) => {
60050
- const { npm: npm13 } = detectPackageManager();
60320
+ const { npm: npm14 } = detectPackageManager();
60051
60321
  let saveFlag;
60052
60322
  let cmd;
60053
- switch (npm13) {
60323
+ switch (npm14) {
60054
60324
  case "yarn":
60055
60325
  cmd = "add";
60056
60326
  saveFlag = config14.dev ? "-D" : "";
60057
60327
  break;
60328
+ case "bun":
60329
+ cmd = "add";
60330
+ saveFlag = config14.dev ? "-d" : "";
60331
+ break;
60058
60332
  case "npm":
60059
60333
  case "pnpm":
60060
60334
  default:
@@ -60062,36 +60336,36 @@ var installPackages = async (packages, config14) => {
60062
60336
  saveFlag = config14.dev ? "--save-dev" : "--save";
60063
60337
  break;
60064
60338
  }
60065
- await runCommand(`${npm13} ${cmd} ${saveFlag} ${packages.join(" ")}`, {
60339
+ await runCommand(`${npm14} ${cmd} ${saveFlag} ${quote(packages)}`, {
60066
60340
  ...config14,
60067
60341
  silent: true
60068
60342
  });
60069
60343
  };
60070
60344
  var npmInstall = async () => {
60071
- const { npm: npm13 } = detectPackageManager();
60072
- await runCommand(`${npm13} install`, {
60345
+ const { npm: npm14 } = detectPackageManager();
60346
+ await runCommand(`${npm14} install`, {
60073
60347
  silent: true,
60074
60348
  startText: "Installing dependencies",
60075
- doneText: `${brandColor("installed")} ${dim(`via \`${npm13} install\``)}`
60349
+ doneText: `${brandColor("installed")} ${dim(`via \`${npm14} install\``)}`
60076
60350
  });
60077
60351
  };
60078
60352
  var resetPackageManager = async (ctx) => {
60079
- const { npm: npm13 } = detectPackageManager();
60080
- if (npm13 === "npm")
60353
+ const { npm: npm14 } = detectPackageManager();
60354
+ if (npm14 === "npm")
60081
60355
  return;
60082
60356
  const nodeModulesPath = import_path5.default.join(ctx.project.path, "node_modules");
60083
60357
  (0, import_fs5.rmSync)(nodeModulesPath, { recursive: true });
60084
60358
  const lockfilePath = import_path5.default.join(ctx.project.path, "package-lock.json");
60085
60359
  (0, import_fs5.rmSync)(lockfilePath);
60086
- await runCommand(`${npm13} install`, {
60360
+ await runCommand(`${npm14} install`, {
60087
60361
  silent: true,
60088
60362
  cwd: ctx.project.path,
60089
60363
  startText: "Installing dependencies",
60090
- doneText: `${brandColor("installed")} ${dim(`via \`${npm13} install\``)}`
60364
+ doneText: `${brandColor("installed")} ${dim(`via \`${npm14} install\``)}`
60091
60365
  });
60092
60366
  };
60093
60367
  var installWrangler = async () => {
60094
- const { npm: npm13 } = detectPackageManager();
60368
+ const { npm: npm14 } = detectPackageManager();
60095
60369
  if ((0, import_fs5.existsSync)(import_path5.default.resolve("node_modules", "wrangler"))) {
60096
60370
  return;
60097
60371
  }
@@ -60101,7 +60375,7 @@ var installWrangler = async () => {
60101
60375
  "A command line tool for building Cloudflare Workers"
60102
60376
  )}`,
60103
60377
  doneText: `${brandColor("installed")} ${dim(
60104
- `via \`${npm13} install wrangler --save-dev\``
60378
+ `via \`${npm14} install wrangler --save-dev\``
60105
60379
  )}`
60106
60380
  });
60107
60381
  };
@@ -60148,8 +60422,8 @@ var listAccounts = async () => {
60148
60422
  return accounts;
60149
60423
  };
60150
60424
  async function getWorkerdCompatibilityDate() {
60151
- const { npm: npm13 } = detectPackageManager();
60152
- return runCommand(`${npm13} info workerd dist-tags.latest`, {
60425
+ const { npm: npm14 } = detectPackageManager();
60426
+ return runCommand(`${npm14} info workerd dist-tags.latest`, {
60153
60427
  silent: true,
60154
60428
  captureOutput: true,
60155
60429
  startText: "Retrieving current workerd compatibility date",
@@ -60600,10 +60874,14 @@ var config6 = {
60600
60874
  var next_default = config6;
60601
60875
 
60602
60876
  // src/frameworks/nuxt/index.ts
60603
- var { dlx: dlx7 } = detectPackageManager();
60877
+ var { npm: npm5, dlx: dlx7 } = detectPackageManager();
60604
60878
  var generate7 = async (ctx) => {
60605
60879
  const cli = getFrameworkCli(ctx);
60606
- await runFrameworkGenerator(ctx, `${dlx7} ${cli} init ${ctx.project.name}`);
60880
+ const gitFlag = ctx.args.git ? `--gitInit` : `--no-gitInit`;
60881
+ await runFrameworkGenerator(
60882
+ ctx,
60883
+ `${dlx7} ${cli} init ${ctx.project.name} --packageManager ${npm5} ${gitFlag}`
60884
+ );
60607
60885
  logRaw("");
60608
60886
  };
60609
60887
  var configure4 = async (ctx) => {
@@ -60617,8 +60895,8 @@ var config7 = {
60617
60895
  displayName: "Nuxt",
60618
60896
  packageScripts: {
60619
60897
  build: (cmd) => `NITRO_PRESET=cloudflare-pages ${cmd}`,
60620
- "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 3000 -- npm run dev`,
60621
- "pages:deploy": "npm run build && wrangler pages deploy ./dist"
60898
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 3000 -- ${npm5} run dev`,
60899
+ "pages:deploy": `${npm5} run build && wrangler pages deploy ./dist`
60622
60900
  }
60623
60901
  };
60624
60902
  var nuxt_default = config7;
@@ -60632,19 +60910,19 @@ var package_default = {
60632
60910
  "additionally it also contains a map that maps frameworks to their respective clis"
60633
60911
  ],
60634
60912
  dependencies: {
60635
- "@angular/cli": "16.2.0",
60636
- "create-astro": "4.0.1",
60913
+ "@angular/cli": "16.2.2",
60914
+ "create-astro": "4.1.0",
60637
60915
  "create-docusaurus": "2.4.1",
60638
60916
  "create-hono": "0.2.6",
60639
60917
  "create-next-app": "13.4.19",
60640
- "create-qwik": "1.2.7",
60918
+ "create-qwik": "1.2.12",
60641
60919
  "create-react-app": "5.0.1",
60642
- "create-remix": "1.19.3",
60643
- "create-solid": "0.2.26",
60644
- "create-svelte": "4.2.0",
60645
- "create-vue": "3.6.4",
60646
- gatsby: "5.11.0",
60647
- nuxi: "3.6.5"
60920
+ "create-remix": "2.0.0",
60921
+ "create-solid": "0.3.6",
60922
+ "create-svelte": "5.1.0",
60923
+ "create-vue": "3.7.5",
60924
+ gatsby: "5.12.4",
60925
+ nuxi: "3.9.0"
60648
60926
  },
60649
60927
  frameworkCliMap: {
60650
60928
  angular: "@angular/cli",
@@ -60664,7 +60942,7 @@ var package_default = {
60664
60942
  };
60665
60943
 
60666
60944
  // src/frameworks/qwik/index.ts
60667
- var { npm: npm5, npx: npx4, dlx: dlx8 } = detectPackageManager();
60945
+ var { npm: npm6, npx: npx4, dlx: dlx8 } = detectPackageManager();
60668
60946
  var generate8 = async (ctx) => {
60669
60947
  const cli = getFrameworkCli(ctx);
60670
60948
  await runFrameworkGenerator(ctx, `${dlx8} ${cli} basic ${ctx.project.name}`);
@@ -60681,14 +60959,14 @@ var config8 = {
60681
60959
  configure: configure5,
60682
60960
  displayName: "Qwik",
60683
60961
  packageScripts: {
60684
- "pages:dev": `wrangler pages dev ${compatDateFlag()} -- ${npm5} run dev`,
60685
- "pages:deploy": `${npm5} run build && wrangler pages deploy ./dist`
60962
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} -- ${npm6} run dev`,
60963
+ "pages:deploy": `${npm6} run build && wrangler pages deploy ./dist`
60686
60964
  }
60687
60965
  };
60688
60966
  var qwik_default = config8;
60689
60967
 
60690
60968
  // src/frameworks/react/index.ts
60691
- var { npm: npm6, dlx: dlx9 } = detectPackageManager();
60969
+ var { npm: npm7, dlx: dlx9 } = detectPackageManager();
60692
60970
  var generate9 = async (ctx) => {
60693
60971
  const cli = getFrameworkCli(ctx);
60694
60972
  await runFrameworkGenerator(ctx, `${dlx9} ${cli} ${ctx.project.name}`);
@@ -60702,14 +60980,14 @@ var config9 = {
60702
60980
  configure: configure6,
60703
60981
  displayName: "React",
60704
60982
  packageScripts: {
60705
- "pages:dev": `wrangler pages dev ${compatDateFlag()} --port 3000 -- ${npm6} start`,
60706
- "pages:deploy": `${npm6} run build && wrangler pages deploy ./build`
60983
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} --port 3000 -- ${npm7} start`,
60984
+ "pages:deploy": `${npm7} run build && wrangler pages deploy ./build`
60707
60985
  }
60708
60986
  };
60709
60987
  var react_default = config9;
60710
60988
 
60711
60989
  // src/frameworks/remix/index.ts
60712
- var { npm: npm7, dlx: dlx10 } = detectPackageManager();
60990
+ var { npm: npm8, dlx: dlx10 } = detectPackageManager();
60713
60991
  var generate10 = async (ctx) => {
60714
60992
  const cli = getFrameworkCli(ctx);
60715
60993
  await runFrameworkGenerator(
@@ -60722,16 +61000,13 @@ var config10 = {
60722
61000
  generate: generate10,
60723
61001
  displayName: "Remix",
60724
61002
  packageScripts: {
60725
- "pages:deploy": `${npm7} run build && wrangler pages deploy ./public`
61003
+ "pages:deploy": `${npm8} run build && wrangler pages deploy ./public`
60726
61004
  },
60727
61005
  devCommand: "dev",
60728
- testFlags: ["--typescript", "--no-install"]
61006
+ testFlags: ["--typescript", "--no-install", "--no-git-init"]
60729
61007
  };
60730
61008
  var remix_default = config10;
60731
61009
 
60732
- // src/frameworks/solid/index.ts
60733
- var import_fs8 = require("fs");
60734
-
60735
61010
  // src/frameworks/solid/templates.ts
60736
61011
  var viteConfig = `
60737
61012
  import solid from "solid-start/vite";
@@ -60744,15 +61019,14 @@ export default defineConfig({
60744
61019
  `;
60745
61020
 
60746
61021
  // src/frameworks/solid/index.ts
60747
- var { npm: npm8, dlx: dlx11 } = detectPackageManager();
61022
+ var { npm: npm9, dlx: dlx11 } = detectPackageManager();
60748
61023
  var generate11 = async (ctx) => {
60749
- (0, import_fs8.mkdirSync)(ctx.project.path);
60750
- process.chdir(ctx.project.path);
60751
61024
  const cli = getFrameworkCli(ctx);
60752
- await runFrameworkGenerator(ctx, `${dlx11} ${cli}`);
61025
+ await runFrameworkGenerator(ctx, `${dlx11} ${cli} ${ctx.project.name}`);
60753
61026
  logRaw("");
60754
61027
  };
60755
- var configure7 = async () => {
61028
+ var configure7 = async (ctx) => {
61029
+ process.chdir(ctx.project.path);
60756
61030
  const pkg = "solid-start-cloudflare-pages";
60757
61031
  await installPackages([pkg], {
60758
61032
  dev: true,
@@ -60762,7 +61036,7 @@ var configure7 = async () => {
60762
61036
  const viteConfigPath = usesTypescript() ? `./vite.config.ts` : `./vite.config.js`;
60763
61037
  writeFile2(viteConfigPath, viteConfig);
60764
61038
  updateStatus(
60765
- `Adding the Cloudflare Pages adapter to ${blue("vite.config.js")}`
61039
+ `Adding the Cloudflare Pages adapter to ${blue(viteConfigPath)}`
60766
61040
  );
60767
61041
  };
60768
61042
  var config11 = {
@@ -60770,8 +61044,8 @@ var config11 = {
60770
61044
  configure: configure7,
60771
61045
  displayName: "Solid",
60772
61046
  packageScripts: {
60773
- "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 3000 -- ${npm8} run dev`,
60774
- "pages:deploy": `${npm8} run build && wrangler pages deploy ./dist/public`
61047
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 3000 -- ${npm9} run dev`,
61048
+ "pages:deploy": `${npm9} run build && wrangler pages deploy ./dist/public`
60775
61049
  }
60776
61050
  };
60777
61051
  var solid_default = config11;
@@ -60823,7 +61097,7 @@ interface Platform {
60823
61097
  `;
60824
61098
 
60825
61099
  // src/frameworks/svelte/index.ts
60826
- var { npm: npm9, dlx: dlx12 } = detectPackageManager();
61100
+ var { npm: npm10, dlx: dlx12 } = detectPackageManager();
60827
61101
  var generate12 = async (ctx) => {
60828
61102
  const cli = getFrameworkCli(ctx);
60829
61103
  await runFrameworkGenerator(ctx, `${dlx12} ${cli} ${ctx.project.name}`);
@@ -60867,14 +61141,14 @@ var config12 = {
60867
61141
  configure: configure8,
60868
61142
  displayName: "Svelte",
60869
61143
  packageScripts: {
60870
- "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 5173 -- ${npm9} run dev`,
60871
- "pages:deploy": `NODE_VERSION=16 ${npm9} run build && wrangler pages deploy .svelte-kit/cloudflare`
61144
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 5173 -- ${npm10} run dev`,
61145
+ "pages:deploy": `${npm10} run build && wrangler pages deploy .svelte-kit/cloudflare`
60872
61146
  }
60873
61147
  };
60874
61148
  var svelte_default = config12;
60875
61149
 
60876
61150
  // src/frameworks/vue/index.ts
60877
- var { npm: npm10, dlx: dlx13 } = detectPackageManager();
61151
+ var { npm: npm11, dlx: dlx13 } = detectPackageManager();
60878
61152
  var generate13 = async (ctx) => {
60879
61153
  const cli = getFrameworkCli(ctx);
60880
61154
  await runFrameworkGenerator(ctx, `${dlx13} ${cli} ${ctx.project.name}`);
@@ -60883,8 +61157,8 @@ var config13 = {
60883
61157
  generate: generate13,
60884
61158
  displayName: "Vue",
60885
61159
  packageScripts: {
60886
- "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 5173 -- ${npm10} run dev`,
60887
- "pages:deploy": `${npm10} run build && wrangler pages deploy ./dist`
61160
+ "pages:dev": `wrangler pages dev ${compatDateFlag()} --proxy 5173 -- ${npm11} run dev`,
61161
+ "pages:deploy": `${npm11} run build && wrangler pages deploy ./dist`
60888
61162
  },
60889
61163
  testFlags: ["--ts"]
60890
61164
  };
@@ -60927,7 +61201,7 @@ var debug = (msg) => {
60927
61201
  };
60928
61202
 
60929
61203
  // src/common.ts
60930
- var import_fs9 = require("fs");
61204
+ var import_fs8 = require("fs");
60931
61205
  var import_path7 = require("path");
60932
61206
  var import_process2 = require("process");
60933
61207
 
@@ -61023,14 +61297,14 @@ function secondsSince(start) {
61023
61297
  }
61024
61298
 
61025
61299
  // ../wrangler/package.json
61026
- var version2 = "3.7.0";
61300
+ var version2 = "3.10.1";
61027
61301
 
61028
61302
  // src/common.ts
61029
- var { name, npm: npm11 } = detectPackageManager();
61303
+ var { name, npm: npm12 } = detectPackageManager();
61030
61304
  var validateProjectDirectory = (relativePath) => {
61031
61305
  const path3 = (0, import_path7.resolve)(relativePath);
61032
- const existsAlready = (0, import_fs9.existsSync)(path3);
61033
- const isEmpty = existsAlready && (0, import_fs9.readdirSync)(path3).length === 0;
61306
+ const existsAlready = (0, import_fs8.existsSync)(path3);
61307
+ const isEmpty = existsAlready && (0, import_fs8.readdirSync)(path3).length === 0;
61034
61308
  if (existsAlready && !isEmpty) {
61035
61309
  return `Directory \`${relativePath}\` already exists and is not empty. Please choose a new name.`;
61036
61310
  }
@@ -61043,13 +61317,13 @@ var setupProjectDirectory = (args) => {
61043
61317
  }
61044
61318
  const directory = (0, import_path7.dirname)(path3);
61045
61319
  const pathBasename = (0, import_path7.basename)(path3);
61046
- (0, import_fs9.mkdirSync)(directory, { recursive: true });
61320
+ (0, import_fs8.mkdirSync)(directory, { recursive: true });
61047
61321
  (0, import_process2.chdir)(directory);
61048
61322
  return { name: pathBasename, path: path3 };
61049
61323
  };
61050
61324
  var offerToDeploy = async (ctx) => {
61051
61325
  startSection(`Deploy with Cloudflare`, `Step 3 of 3`);
61052
- const label = `deploy via \`${npm11} run ${ctx.framework?.config.deployCommand ?? "deploy"}\``;
61326
+ const label = `deploy via \`${npm12} run ${ctx.framework?.config.deployCommand ?? "deploy"}\``;
61053
61327
  ctx.args.deploy = await processArgument(ctx.args, "deploy", {
61054
61328
  type: "confirm",
61055
61329
  question: "Do you want to deploy your application?",
@@ -61071,7 +61345,7 @@ var runDeploy = async (ctx) => {
61071
61345
  return;
61072
61346
  }
61073
61347
  const baseDeployCmd = [
61074
- npm11,
61348
+ npm12,
61075
61349
  "run",
61076
61350
  ctx.framework?.config.deployCommand ?? "deploy"
61077
61351
  ];
@@ -61093,7 +61367,7 @@ var runDeploy = async (ctx) => {
61093
61367
  env: { CLOUDFLARE_ACCOUNT_ID: ctx.account.id, NODE_ENV: "production" },
61094
61368
  startText: "Deploying your application",
61095
61369
  doneText: `${brandColor("deployed")} ${dim(
61096
- `via \`${baseDeployCmd.join(" ")}\``
61370
+ `via \`${quote(baseDeployCmd)}\``
61097
61371
  )}`
61098
61372
  });
61099
61373
  const deployedUrlRegex = /https:\/\/.+\.(pages|workers)\.dev/;
@@ -61146,11 +61420,11 @@ var printSummary = async (ctx) => {
61146
61420
  [`Navigate to the new directory`, `cd ${ctx.project.name}`],
61147
61421
  [
61148
61422
  `Run the development server`,
61149
- `${npm11} run ${ctx.framework?.config.devCommand ?? "start"}`
61423
+ `${npm12} run ${ctx.framework?.config.devCommand ?? "start"}`
61150
61424
  ],
61151
61425
  [
61152
61426
  `Deploy your application`,
61153
- `${npm11} run ${ctx.framework?.config.deployCommand ?? "deploy"}`
61427
+ `${npm12} run ${ctx.framework?.config.deployCommand ?? "deploy"}`
61154
61428
  ],
61155
61429
  [
61156
61430
  `Read the documentation`,
@@ -61172,7 +61446,7 @@ var printSummary = async (ctx) => {
61172
61446
  `${bgGreen(" APPLICATION CREATED ")}`,
61173
61447
  `${dim(`Deploy your application with`)}`,
61174
61448
  `${blue(
61175
- `${npm11} run ${ctx.framework?.config.deployCommand ?? "deploy"}`
61449
+ `${npm12} run ${ctx.framework?.config.deployCommand ?? "deploy"}`
61176
61450
  )}`
61177
61451
  ].join(" ");
61178
61452
  logRaw(msg);
@@ -61528,6 +61802,7 @@ async function copyFiles(ctx) {
61528
61802
  const destdir = ctx.project.path;
61529
61803
  updateStatus(`Copying files from "${template}" template`);
61530
61804
  await (0, import_promises2.cp)(srcdir, destdir, { recursive: true });
61805
+ await (0, import_promises2.rename)((0, import_path9.join)(destdir, "__dot__gitignore"), (0, import_path9.join)(destdir, ".gitignore"));
61531
61806
  }
61532
61807
  async function copyExistingWorkerFiles(ctx) {
61533
61808
  const { preexisting } = await getTemplate(ctx);
@@ -61627,6 +61902,13 @@ var templateMap = {
61627
61902
  ts: true
61628
61903
  })
61629
61904
  },
61905
+ openapi: {
61906
+ label: `OpenAPI 3.1`,
61907
+ handler: (args) => runWorkersGenerator({
61908
+ ...args,
61909
+ ts: true
61910
+ })
61911
+ },
61630
61912
  "pre-existing": {
61631
61913
  label: "Pre-existing Worker (from Dashboard)",
61632
61914
  handler: runWorkersGenerator,
@@ -61683,7 +61965,7 @@ var processArgument = async (args, name2, promptConfig) => {
61683
61965
 
61684
61966
  // src/cli.ts
61685
61967
  var import_semver2 = __toESM(require_semver2());
61686
- var { npm: npm12 } = detectPackageManager();
61968
+ var { npm: npm13 } = detectPackageManager();
61687
61969
  var main = async (argv) => {
61688
61970
  const args = await parseArgs(argv);
61689
61971
  logRaw("");
@@ -61710,7 +61992,7 @@ var isUpdateAvailable = async () => {
61710
61992
  };
61711
61993
  var runLatest = async () => {
61712
61994
  const args = process.argv.slice(2);
61713
- await runCommand(`${npm12} create cloudflare@latest ${args.join(" ")}`);
61995
+ await runCommand(`${npm13} create cloudflare@latest ${args.join(" ")}`);
61714
61996
  };
61715
61997
  var runCli = async (args) => {
61716
61998
  printBanner();