-
Notifications
You must be signed in to change notification settings - Fork 0
/
sao.js
48 lines (47 loc) · 1.02 KB
/
sao.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
const superb = require('superb')
module.exports = {
prompts: {
name: {
message: 'Plugin name?',
default: ':folderName:'
},
description: {
message: 'Description:',
default: `my ${superb()} project`
},
username: {
message: 'Your name:',
default: ':gitUser:',
store: true
},
email: {
message: 'Your email:',
default: ':gitEmail:',
store: true
},
website: {
message: 'The URL of your website?',
default({ username }) {
return `github.com/${username}`
},
store: true
}
},
move: {
'gitignore': '.gitignore'
},
showTip: true,
gitInit: true,
installDependencies: true,
post({ log, isNewFolder, folderName, chalk }) {
console.log()
log.success(`Successfully generated into ${chalk.cyan(folderName)}`)
console.log()
console.log(chalk.bold('To get started:\n'))
if (isNewFolder) {
console.log(` cd ${folderName}`)
}
console.log(' npm start')
console.log()
}
}