Add 3 new options. Fix #241.

This commit is contained in:
Petr Korolev 2015-06-12 11:23:32 +03:00
parent c480075e8e
commit 4f21ae7768
3 changed files with 24 additions and 2 deletions

View File

@ -1,5 +1,5 @@
# This configuration was generated by `rubocop --auto-gen-config` # This configuration was generated by `rubocop --auto-gen-config`
# on 2015-06-11 16:35:14 +0300 using RuboCop version 0.31.0. # on 2015-06-12 11:23:12 +0300 using RuboCop version 0.31.0.
# The point is for the user to remove these configuration records # The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base. # one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new # Note that changes in the inspected code, or installation of new
@ -7,7 +7,7 @@
# Offense count: 13 # Offense count: 13
Metrics/AbcSize: Metrics/AbcSize:
Max: 63 Max: 71
# Offense count: 1 # Offense count: 1
Metrics/CyclomaticComplexity: Metrics/CyclomaticComplexity:

View File

@ -4,8 +4,18 @@
[Full Changelog](https://github.com/skywinder/changelog_test/compare/0.0.4...HEAD) [Full Changelog](https://github.com/skywinder/changelog_test/compare/0.0.4...HEAD)
**Implemented enhancements:**
- Enchancment [\#9](https://github.com/skywinder/changelog_test/issues/9)
**Fixed bugs:**
- BugFix [\#11](https://github.com/skywinder/changelog_test/issues/11)
**Closed issues:** **Closed issues:**
- Issue [\#10](https://github.com/skywinder/changelog_test/issues/10)
- Issue with some other label - Should be in closed issues [\#8](https://github.com/skywinder/changelog_test/issues/8) - Issue with some other label - Should be in closed issues [\#8](https://github.com/skywinder/changelog_test/issues/8)
## [0.0.4](https://github.com/skywinder/changelog_test/tree/0.0.4) (2015-05-22) ## [0.0.4](https://github.com/skywinder/changelog_test/tree/0.0.4) (2015-05-22)

View File

@ -50,6 +50,18 @@ module GitHubChangelogGenerator
opts.on("-o", "--output [NAME]", "Output file. Default is CHANGELOG.md") do |last| opts.on("-o", "--output [NAME]", "Output file. Default is CHANGELOG.md") do |last|
options[:output] = last options[:output] = last
end end
opts.on("--bugs-label [LABEL]", "Setup custom label for bug-fixes section. Default is \"**Fixed bugs:**""") do |v|
options[:bug_prefix] = v
end
opts.on("--enhancement-label [LABEL]", "Setup custom label for enhancements section. Default is \"**Implemented enhancements:**\"") do |v|
options[:enhancement_prefix] = v
end
opts.on("--issues-label [LABEL]", "Setup custom label for closed-issues section. Default is \"**Closed issues:**\"") do |v|
options[:issue_prefix] = v
end
opts.on("--pr-label [LABEL]", "Setup custom label for pull requests section. Default is \"**Merged pull requests:**\"") do |v|
options[:merge_prefix] = v
end
opts.on("--[no-]issues", "Include closed issues in changelog. Default is true") do |v| opts.on("--[no-]issues", "Include closed issues in changelog. Default is true") do |v|
options[:issues] = v options[:issues] = v
end end