create-redwood-rsc-app
Advanced tools
Comparing version 0.6.4 to 0.7.0
@@ -5,2 +5,3 @@ import { ExitCodeError } from "./error.js"; | ||
installationDir: "", | ||
printVersion: false, | ||
template: "", | ||
@@ -22,6 +23,3 @@ verbose: false | ||
} else if (arg === "--version" || arg === "-V") { | ||
console.log(); | ||
console.log("--version is not implemented yet"); | ||
console.log("PR welcome!"); | ||
console.log(); | ||
config.printVersion = true; | ||
} else if (arg.startsWith("--template") || arg.startsWith("-t")) { | ||
@@ -49,3 +47,3 @@ const templateIndex = i + 2; | ||
} | ||
if (positionals.length === 0) { | ||
if (positionals.length === 0 && !config.printVersion) { | ||
throw new ExitCodeError(1, "Error: No installation directory provided"); | ||
@@ -52,0 +50,0 @@ } |
@@ -13,2 +13,3 @@ #!/usr/bin/env node | ||
import { upgradeToLatestCanary } from "./upgradeToLatestCanary.js"; | ||
import { printVersion } from "./version.js"; | ||
import { unzip } from "./zip.js"; | ||
@@ -20,3 +21,5 @@ const startTime = Date.now(); | ||
telemetryInfo.template = config.template; | ||
if (shouldRelaunch(config)) { | ||
if (config.printVersion) { | ||
printVersion(); | ||
} else if (shouldRelaunch(config)) { | ||
relaunchOnLatest(config); | ||
@@ -23,0 +26,0 @@ } else { |
{ | ||
"name": "create-redwood-rsc-app", | ||
"version": "0.6.4", | ||
"version": "0.7.0", | ||
"description": "Quickstart for a RedwoodJS React Server Components App", | ||
@@ -5,0 +5,0 @@ "repository": { |
24196
16
683