Comparing version 0.19.0 to 0.19.1
@@ -50,2 +50,5 @@ 'use strict' | ||
let data // mock prompt data | ||
let installDependencies | ||
let gitInit | ||
let showTip | ||
@@ -58,2 +61,5 @@ if (projectConfig) { | ||
filters = projectConfig.filters | ||
installDependencies = projectConfig.installDependencies | ||
gitInit = projectConfig.gitInit | ||
showTip = projectConfig.showTip | ||
// move files | ||
@@ -168,9 +174,22 @@ move = projectConfig.move | ||
$.exec('git init', { cwd: folderPath }) | ||
}, | ||
showTip: () => { | ||
log.success('Done, let the hacking begin!') | ||
if (isNewFolder) { | ||
log.info(`cd ${folderName} to get started!`) | ||
} | ||
} | ||
}, templateContext) | ||
if (gitInit) { | ||
actionContext.init() | ||
} | ||
if (installDependencies) { | ||
actionContext.install() | ||
} | ||
const action = postAction && postAction(actionContext) | ||
if (action && action.then) return action.then(() => res) | ||
if (!postAction) { | ||
if (!postAction || showTip) { | ||
// when there's no post action | ||
@@ -177,0 +196,0 @@ // it will sliently finished the process |
{ | ||
"name": "sao", | ||
"version": "0.19.0", | ||
"version": "0.19.1", | ||
"description": "Futuristic project generator.", | ||
@@ -77,2 +77,2 @@ "license": "MIT", | ||
} | ||
} | ||
} |
27047
480