Skip to content
This repository has been archived by the owner on Dec 14, 2018. It is now read-only.

Commit

Permalink
Make CLI arguments override plugin config
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Jul 7, 2014
1 parent b5564ca commit c2cee35
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions tasks/release-it.js
Expand Up @@ -6,13 +6,13 @@ module.exports = function(grunt) {

var done = this.async();

var options = this.options({
increment: increment,
verbose: !!grunt.option('verbose'),
debug: !!grunt.option('debug'),
force: !!grunt.option('force'),
'dry-run' : !!grunt.option('no-write')
});
var options = this.options();

options.increment = increment || options.increment;
options.verbose = grunt.option('verbose') === true || options.verbose;
options.debug = grunt.option('debug') === true || options.debug;
options.force = grunt.option('force') === true || options.force;
options['dry-run'] = grunt.option('no-write') === true || options['dry-run'];

release.execute(options).catch(grunt.fail.warn).finally(done);

Expand Down

0 comments on commit c2cee35

Please sign in to comment.