create-better-schemic 0.1.0-alpha.10 → 0.1.0-alpha.12

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/lib/index.js CHANGED
@@ -1256,7 +1256,7 @@ ${i}
1256
1256
  }
1257
1257
  }).prompt();
1258
1258
  // package.json
1259
- var version = "0.1.0-alpha.10";
1259
+ var version = "0.1.0-alpha.12";
1260
1260
 
1261
1261
  // src/index.ts
1262
1262
  var RANGE = `^${version}`;
@@ -1463,6 +1463,10 @@ async function main() {
1463
1463
  initialValue: true
1464
1464
  })) : true;
1465
1465
  let pm = opts.pm ?? detected;
1466
+ if (!PMS.includes(pm)) {
1467
+ cancel(`Unknown package manager "${pm}". Known: ${PMS.join(", ")}.`);
1468
+ process.exit(1);
1469
+ }
1466
1470
  if (install && !opts.pm && tty) {
1467
1471
  pm = abortIfCancel(await select({
1468
1472
  message: "Install with which package manager?",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-better-schemic",
3
- "version": "0.1.0-alpha.10",
3
+ "version": "0.1.0-alpha.12",
4
4
  "description": "Scaffold a new Better-schemic project — package.json, tsconfig, a driver, and the database/ schema, in one command.",
5
5
  "license": "MIT",
6
6
  "author": "Vertio Solutions",
package/src/index.ts CHANGED
@@ -285,6 +285,10 @@ async function main(): Promise<void> {
285
285
  )
286
286
  : true;
287
287
  let pm: Pm = (opts.pm as Pm) ?? detected;
288
+ if (!PMS.includes(pm)) {
289
+ p.cancel(`Unknown package manager "${pm}". Known: ${PMS.join(", ")}.`);
290
+ process.exit(1);
291
+ }
288
292
  if (install && !opts.pm && tty) {
289
293
  pm = abortIfCancel(
290
294
  await p.select({