Make 'change log' a single word (#579)

This commit is contained in:
Saugat Acharya
2017-12-14 02:51:00 +05:45
committed by Olle Jonsson
parent d5f82c5994
commit d9cf6ffd94
15 changed files with 48 additions and 48 deletions
@@ -14,7 +14,7 @@ module GitHubChangelogGenerator
class Generator
attr_accessor :options, :filtered_tags, :github, :tag_section_mapping, :sorted_tags
# A Generator responsible for all logic, related with change log generation from ready-to-parse issues
# A Generator responsible for all logic, related with changelog generation from ready-to-parse issues
#
# Example:
# generator = GitHubChangelogGenerator::Generator.new
@@ -2,9 +2,9 @@
module GitHubChangelogGenerator
class Generator
# Main function to start change log generation
# Main function to start changelog generation
#
# @return [String] Generated change log file
# @return [String] Generated changelog file
def compound_changelog
options.load_custom_ruby_files
fetch_and_filter_tags
@@ -22,7 +22,7 @@ module GitHubChangelogGenerator
log += File.read(options[:base]) if File.file?(options[:base])
credit_line = "\n\n\\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*"
credit_line = "\n\n\\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*"
log.gsub!(credit_line, "") # Remove old credit lines
log += credit_line
@@ -113,7 +113,7 @@ module GitHubChangelogGenerator
end
# The full cycle of generation for whole project
# @return [String] The complete change log
# @return [String] The complete changelog
def generate_log_for_all_tags
puts "Generating log..." if options[:verbose]
@@ -13,7 +13,7 @@ module GitHubChangelogGenerator
MAX_THREAD_NUMBER = 25
MAX_FORBIDDEN_RETRIES = 100
CHANGELOG_GITHUB_TOKEN = "CHANGELOG_GITHUB_TOKEN"
GH_RATE_LIMIT_EXCEEDED_MSG = "Warning: Can't finish operation: GitHub API rate limit exceeded, change log may be " \
GH_RATE_LIMIT_EXCEEDED_MSG = "Warning: Can't finish operation: GitHub API rate limit exceeded, changelog may be " \
"missing some issues. You can limit the number of issues fetched using the `--max-issues NUM` argument."
NO_TOKEN_PROVIDED = "Warning: No token provided (-t option) and variable $CHANGELOG_GITHUB_TOKEN was not found. " \
"This script can make only 50 requests to GitHub API per hour without token!"
+5 -5
View File
@@ -68,7 +68,7 @@ module GitHubChangelogGenerator
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("--header-label [LABEL]", "Setup custom header label. Default is \"# Change Log\"") do |v|
opts.on("--header-label [LABEL]", "Setup custom header label. Default is \"# Changelog\"") do |v|
options[:header] = v
end
opts.on("--front-matter [JSON]", "Add YAML front matter. Formatted as JSON because it's easier to add on the command line") do |v|
@@ -128,16 +128,16 @@ module GitHubChangelogGenerator
opts.on("--issue-line-labels x,y,z", Array, 'The specified labels will be shown in brackets next to each matching issue. Use "ALL" to show all labels. Default is [].') do |list|
options[:issue_line_labels] = list
end
opts.on("--exclude-tags x,y,z", Array, "Change log will exclude specified tags") do |list|
opts.on("--exclude-tags x,y,z", Array, "Changelog will exclude specified tags") do |list|
options[:exclude_tags] = list
end
opts.on("--exclude-tags-regex [REGEX]", "Apply a regular expression on tag names so that they can be excluded, for example: --exclude-tags-regex \".*\+\d{1,}\" ") do |last|
options[:exclude_tags_regex] = last
end
opts.on("--since-tag x", "Change log will start after specified tag") do |v|
opts.on("--since-tag x", "Changelog will start after specified tag") do |v|
options[:since_tag] = v
end
opts.on("--due-tag x", "Change log will end before specified tag") do |v|
opts.on("--due-tag x", "Changelog will end before specified tag") do |v|
options[:due_tag] = v
end
opts.on("--max-issues [NUMBER]", Integer, "Max number of issues to fetch from GitHub. Default is unlimited") do |max|
@@ -214,7 +214,7 @@ module GitHubChangelogGenerator
simple_list: false,
ssl_ca_file: nil,
verbose: true,
header: "# Change Log",
header: "# Changelog",
merge_prefix: "**Merged pull requests:**",
issue_prefix: "**Closed issues:**",
bug_prefix: "**Fixed bugs:**",
+1 -1
View File
@@ -38,7 +38,7 @@ module GitHubChangelogGenerator
end
def define(args, &task_block)
desc "Generate a Change log from GitHub"
desc "Generate a Changelog from GitHub"
yield(*[self, args].slice(0, task_block.arity)) if task_block