From 7bb5365bd4175052f1b9f6bb0d345aa99d54c98c Mon Sep 17 00:00:00 2001 From: Boris Staal Date: Thu, 28 Nov 2013 18:15:48 +0700 Subject: [PATCH] Deprecation for `--output-dir` has been added (#140) --- lib/command.coffee | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/command.coffee b/lib/command.coffee index 050c047..93778df 100644 --- a/lib/command.coffee +++ b/lib/command.coffee @@ -9,6 +9,7 @@ module.exports = class Command {name: 'help', alias: 'h', describe: 'Show this help'} {name: 'version', describe: 'Show version'} {name: 'output', alias: 'o', describe: 'The output directory', default: './doc'} + {name: 'output-dir'} {name: 'theme', describe: 'The theme to be used', default: 'default'} {name: 'name', alias: 'n', describe: 'The project name used'} {name: 'readme', alias: 'r', describe: 'The readme file used'} @@ -70,6 +71,10 @@ module.exports = class Command @options = @prepareOptions(optimist, defaults) + if @options['output-dir'] + console.log "The usage of outdated `--output-dir` option detected. Please switch to `--output`." + process.exit() + if @options.help console.log optimist.help() else if @options.version