@@ -107,31 +107,32 @@ export async function addIconify({ name }) {
107
107
)
108
108
}
109
109
110
- void ( async function ( ) {
111
- const opts = {
112
- name : argv . _ [ 0 ] ,
113
- template : argv . t || 'skeleton'
114
- }
115
- if ( ! opts . name ) {
116
- echo `Error: please specify the app name`
117
- process . exit ( 1 )
118
- }
119
- if ( ( await fs . pathExists ( opts . name ) ) && ! argv . o ) {
120
- echo `Error: path ${ path . sep } ${ opts . name } already exists, specify -o flag to overwrite`
121
- process . exit ( 1 )
122
- }
110
+ const opts = {
111
+ name : argv . _ [ 0 ] ,
112
+ template : argv . t || 'skeleton'
113
+ }
114
+ if ( ! opts . name ) {
115
+ echo `Error: please specify the app name`
116
+ process . exit ( 1 )
117
+ }
118
+ if ( ( await fs . pathExists ( opts . name ) ) && ! argv . o ) {
119
+ echo `Error: path ${ path . sep } ${ opts . name } already exists, specify -o flag to overwrite`
120
+ process . exit ( 1 )
121
+ }
122
+
123
+ await addBaseTemplate ( opts ) . then ( ( ) => echo `- created ${ opts . template } template` )
124
+ await addTailwindcss ( opts ) . then ( ( ) => echo `- added tailwindcss` )
125
+ await addPrettier ( opts ) . then ( ( ) => echo `- patched prettier config` )
126
+ await addEslint ( opts ) . then ( ( ) => echo `- patched eslint config` )
127
+ await addAdapterStatic ( opts ) . then ( ( ) => echo `- added adapter-static` )
128
+ await addFontsource ( opts ) . then ( ( ) => echo `- added fontsource` )
129
+ await addIconify ( opts ) . then ( ( ) => echo `- added iconify` )
123
130
124
- await addBaseTemplate ( opts ) . then ( ( ) => echo `- created ${ opts . template } template` )
125
- await addTailwindcss ( opts ) . then ( ( ) => echo `- added tailwindcss` )
126
- await addPrettier ( opts ) . then ( ( ) => echo `- patched prettier config` )
127
- await addEslint ( opts ) . then ( ( ) => echo `- patched eslint config` )
128
- await addAdapterStatic ( opts ) . then ( ( ) => echo `- added adapter-static` )
129
- await addFontsource ( opts ) . then ( ( ) => echo `- added fontsource` )
130
- await addIconify ( opts ) . then ( ( ) => echo `- added iconify` )
131
+ echo `
132
+ All done! Complete the setup with:
131
133
132
- echo `\nAll done! Complete the setup with:\n`
133
- echo `$ cd ${ opts . name } `
134
- echo `$ npx npm-check-updates -u`
135
- echo `$ npm i`
136
- echo `$ npm run format`
137
- } ) ( )
134
+ $ cd ${ opts . name }
135
+ $ npx npm-check-updates -u
136
+ $ npm i
137
+ $ npm run format
138
+ `
0 commit comments