diff --git a/.changeset/violet-apricots-smash.md b/.changeset/violet-apricots-smash.md new file mode 100644 index 000000000..eb472b8a8 --- /dev/null +++ b/.changeset/violet-apricots-smash.md @@ -0,0 +1,5 @@ +--- +'create-astro': patch +--- + +fix error when don't have template input diff --git a/packages/create-astro/src/index.ts b/packages/create-astro/src/index.ts index aa1024329..55b285e89 100644 --- a/packages/create-astro/src/index.ts +++ b/packages/create-astro/src/index.ts @@ -163,7 +163,7 @@ export async function main() { { onCancel: () => ora().info(dim('Operation cancelled. See you later, astronaut!')) } ); - if (!options.template) { + if (!options.template || options.template === true) { ora().info(dim('No template provided. See you later, astronaut!')); process.exit(1); }