cli: add --no-push flag to allow testing

This commit is contained in:
Matthias Rolke 2016-01-13 16:12:17 +01:00
parent c11cfac67e
commit 7139ad7364

View file

@ -18,6 +18,7 @@ program
'commit message', 'Updates')
.option('-t, --dotfiles', 'Include dotfiles')
.option('-a, --add', 'Only add, and never remove existing files.')
.option('-n, --no-push', 'Commit only (with no push)')
.parse(process.argv);
ghpages.publish(path.join(process.cwd(), program.dist), {
@ -27,6 +28,7 @@ ghpages.publish(path.join(process.cwd(), program.dist), {
message: program.message,
dotfiles: !!program.dotfiles,
add: !!program.add,
push: !program.noPush,
logger: function(message) {
process.stderr.write(message + '\n');
}