@@ -66,14 +66,14 @@ export const create = new Command('create')
66
66
const highlight = ( str : string ) => pc . bold ( pc . cyan ( str ) ) ;
67
67
68
68
let i = 1 ;
69
- const initialSteps : string [ ] = [ ] ;
69
+ const initialSteps : string [ ] = [ 'π Project steps' , '' ] ;
70
70
const relative = path . relative ( process . cwd ( ) , directory ) ;
71
71
const pm =
72
72
packageManager ?? ( await detect ( { cwd : directory } ) ) ?. name ?? getUserAgent ( ) ?? 'npm' ;
73
73
if ( relative !== '' ) {
74
74
const pathHasSpaces = relative . includes ( ' ' ) ;
75
75
initialSteps . push (
76
- `${ i ++ } : ${ highlight ( `cd ${ pathHasSpaces ? `"${ relative } "` : relative } ` ) } `
76
+ ` ${ i ++ } : ${ highlight ( `cd ${ pathHasSpaces ? `"${ relative } "` : relative } ` ) } `
77
77
) ;
78
78
}
79
79
if ( ! packageManager ) {
@@ -85,16 +85,23 @@ export const create = new Command('create')
85
85
const pmRunCmd = `${ command } ${ args . join ( ' ' ) } ` ;
86
86
const steps = [
87
87
...initialSteps ,
88
- `${ i ++ } : ${ highlight ( 'git init && git add -A && git commit -m "Initial commit"' ) } (optional)` ,
89
- `${ i ++ } : ${ highlight ( pmRunCmd ) } ` ,
88
+ ` ${ i ++ } : ${ highlight ( 'git init && git add -A && git commit -m "Initial commit"' ) } (optional)` ,
89
+ ` ${ i ++ } : ${ highlight ( pmRunCmd ) } ` ,
90
90
'' ,
91
- `To close the dev server, hit ${ highlight ( 'Ctrl-C' ) } ` ,
92
- '' ,
93
- `Stuck? Visit us at ${ pc . cyan ( 'https://svelte.dev/chat' ) } `
91
+ `To close the dev server, hit ${ highlight ( 'Ctrl-C' ) } `
94
92
] ;
95
93
96
- p . note ( steps . join ( '\n' ) , 'Project next steps' , { format : ( line ) => line } ) ;
97
- if ( addOnNextSteps ) p . note ( addOnNextSteps , 'Add-on next steps' , { format : ( line ) => line } ) ;
94
+ if ( addOnNextSteps . length > 0 ) {
95
+ steps . push ( '' , 'π§© Add-on steps' , '' ) ;
96
+ for ( const step of addOnNextSteps ) {
97
+ const indented = step . replaceAll ( ' -' , ' -' ) ;
98
+ steps . push ( ` ${ indented } ` ) ;
99
+ }
100
+ }
101
+
102
+ steps . push ( '' , `Stuck? Visit us at ${ pc . cyan ( 'https://svelte.dev/chat' ) } ` ) ;
103
+
104
+ p . note ( steps . join ( '\n' ) , "What's next?" , { format : ( line ) => line } ) ;
98
105
} ) ;
99
106
} ) ;
100
107
@@ -166,7 +173,7 @@ async function createProject(cwd: ProjectPath, options: Options) {
166
173
p . log . success ( 'Project created' ) ;
167
174
168
175
let packageManager : AgentName | undefined | null ;
169
- let addOnNextSteps : string | undefined ;
176
+ let addOnNextSteps : string [ ] = [ ] ;
170
177
171
178
const installDeps = async ( install : true | AgentName ) => {
172
179
packageManager = install === true ? await packageManagerPrompt ( projectPath ) : install ;
0 commit comments