lib/docman/cli.rb in docman-0.0.62 vs lib/docman/cli.rb in docman-0.0.63
- old
+ new
@@ -61,18 +61,16 @@
say(result, :green)
end
end
desc 'bump', 'Bump version'
+ method_option :next, :aliases => '-n', :desc => 'Automatically use next version number'
#option :state
#option :skip
def bump(state = nil, skip = nil)
- # if state
- # Exec.do "#{Application::bin}/bump-version.sh #{state}"
- # else
- # Exec.do "#{Application::bin}/bump-version.sh"
- # end
- Exec.do "#{Application::bin}/bump-version.sh #{state} #{skip}"
+ version_number = options[:next] ? 'next' : 'ask'
+
+ Exec.do "#{Application::bin}/bump-version.sh #{state} #{version_number} #{skip}"
say('Complete!', :green)
end
desc 'template', 'Reinit project from template'
method_option :force, :aliases => '-f', :desc => 'Force project override with template'
\ No newline at end of file