@@ -12,8 +12,9 @@ import {
1212} from 'node:fs' ;
1313import { join , resolve } from 'node:path' ;
1414import { parseArgs } from 'node:util' ;
15- import { isCancel , select , text , log } from '@clack/prompts' ;
15+ import { isCancel , select , text , log } from '@clack/prompts' ;
1616import { kebabCase } from 'es-toolkit' ;
17+ import { execSync } from 'node:child_process' ;
1718
1819const engines = [ 'deno' , 'node' , 'bun' ] as const ;
1920type Engine = ( typeof engines ) [ number ] ;
@@ -91,7 +92,7 @@ async function ensureName(name?: string): Promise<string> {
9192async function ensureTargetDir ( name : string , target ?: string ) : Promise < string > {
9293 if ( target ) return target ;
9394
94- const defaultName = kebabCase ( name ) ;
95+ const defaultName = `./ ${ kebabCase ( name ) } ` ;
9596
9697 const response = await text ( {
9798 message : 'Where should the template be copied?' ,
@@ -208,7 +209,7 @@ async function main() {
208209 updateProjectName ( targetPath , name ) ;
209210
210211 if ( args . values . git ) {
211- existsSync ( 'git init' ) ;
212+ execSync ( 'git init' ) ;
212213 }
213214
214215 log . success ( `✅ Template "${ engine } " copied to "${ targetPath } "` ) ;
0 commit comments