@betterstart/cli 0.1.8 → 0.1.9
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/dist/cli.js +4 -2
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -7978,6 +7978,7 @@ async function promptProject(defaultName) {
|
|
|
7978
7978
|
defaultValue: defaultName ?? "my-app",
|
|
7979
7979
|
validate: (value) => {
|
|
7980
7980
|
if (!value.trim()) return "Project name is required";
|
|
7981
|
+
if (value.trim() === ".") return void 0;
|
|
7981
7982
|
if (!/^[a-z0-9_-]+$/i.test(value.trim())) {
|
|
7982
7983
|
return "Project name can only contain letters, numbers, hyphens, and underscores";
|
|
7983
7984
|
}
|
|
@@ -13626,7 +13627,8 @@ var initCommand = new Command3("init").description("Scaffold CMS into a new or e
|
|
|
13626
13627
|
pm = pmChoice;
|
|
13627
13628
|
}
|
|
13628
13629
|
const cnaSpinner = p4.spinner();
|
|
13629
|
-
|
|
13630
|
+
const displayName = projectPrompt.projectName === "." ? path37.basename(cwd) : projectPrompt.projectName;
|
|
13631
|
+
cnaSpinner.start(`Creating Next.js app: ${displayName}...`);
|
|
13630
13632
|
try {
|
|
13631
13633
|
const cnaArgs = [
|
|
13632
13634
|
"create-next-app@latest",
|
|
@@ -13646,7 +13648,7 @@ var initCommand = new Command3("init").description("Scaffold CMS into a new or e
|
|
|
13646
13648
|
stdio: "pipe",
|
|
13647
13649
|
timeout: 12e4
|
|
13648
13650
|
});
|
|
13649
|
-
cnaSpinner.stop(`Created ${
|
|
13651
|
+
cnaSpinner.stop(`Created ${displayName}`);
|
|
13650
13652
|
} catch (err) {
|
|
13651
13653
|
cnaSpinner.stop("Failed to create Next.js app");
|
|
13652
13654
|
p4.log.error(err instanceof Error ? err.message : "create-next-app failed");
|