github_changelog_generator 1.15.0.pre.alpha → 1.16.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/LICENSE +1 -1
- data/README.md +332 -275
- data/Rakefile +3 -4
- data/bin/git-generate-changelog +1 -1
- data/lib/github_changelog_generator.rb +10 -6
- data/lib/github_changelog_generator/generator/entry.rb +218 -0
- data/lib/github_changelog_generator/generator/generator.rb +126 -104
- data/lib/github_changelog_generator/generator/generator_fetcher.rb +139 -23
- data/lib/github_changelog_generator/generator/generator_processor.rb +59 -27
- data/lib/github_changelog_generator/generator/generator_tags.rb +26 -22
- data/lib/github_changelog_generator/generator/section.rb +124 -0
- data/lib/github_changelog_generator/helper.rb +1 -1
- data/lib/github_changelog_generator/octo_fetcher.rb +261 -130
- data/lib/github_changelog_generator/options.rb +74 -1
- data/lib/github_changelog_generator/parser.rb +120 -176
- data/lib/github_changelog_generator/parser_file.rb +8 -3
- data/lib/github_changelog_generator/reader.rb +2 -2
- data/lib/github_changelog_generator/task.rb +5 -6
- data/lib/github_changelog_generator/version.rb +1 -1
- data/man/git-generate-changelog.1 +144 -45
- data/man/git-generate-changelog.1.html +157 -84
- data/man/git-generate-changelog.html +19 -7
- data/man/git-generate-changelog.md +151 -84
- data/spec/files/github-changelog-generator.md +114 -114
- data/spec/{install-gem-in-bundler.gemfile → install_gem_in_bundler.gemfile} +2 -0
- data/spec/spec_helper.rb +2 -6
- data/spec/unit/generator/entry_spec.rb +766 -0
- data/spec/unit/generator/generator_processor_spec.rb +103 -41
- data/spec/unit/generator/generator_spec.rb +47 -0
- data/spec/unit/generator/generator_tags_spec.rb +56 -24
- data/spec/unit/generator/section_spec.rb +34 -0
- data/spec/unit/octo_fetcher_spec.rb +247 -197
- data/spec/unit/options_spec.rb +28 -4
- data/spec/unit/parse_file_spec.rb +2 -2
- data/spec/unit/parser_spec.rb +0 -79
- data/spec/unit/reader_spec.rb +4 -4
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_commits/when_API_is_valid/returns_commits.json +1 -0
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_commits_before/when_API_is_valid/returns_commits.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid/returns_issue_with_proper_key/values.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid/returns_issues.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid/returns_issues_with_labels.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid/returns_pull_request_with_proper_key/values.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_issues_and_pr/when_API_call_is_valid/returns_pull_requests_with_labels.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_pull_requests/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_pull_requests/when_API_call_is_valid/returns_correct_pull_request_keys.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_closed_pull_requests/when_API_call_is_valid/returns_pull_requests.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_commit/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_commit/when_API_call_is_valid/returns_commit.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_date_of_tag/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_date_of_tag/when_API_call_is_valid/returns_date.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_events_async/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_fetch_events_async/when_API_call_is_valid/populates_issues.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_github_fetch_tags/when_API_call_is_valid.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_github_fetch_tags/when_API_call_is_valid/should_return_tags.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_github_fetch_tags/when_API_call_is_valid/should_return_tags_count.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_github_fetch_tags/when_wrong_token_provided.json +1 -1
- data/spec/vcr/GitHubChangelogGenerator_OctoFetcher/_github_fetch_tags/when_wrong_token_provided/should_raise_Unauthorized_error.json +1 -1
- metadata +71 -38
- data/bin/ghclgen +0 -5
- data/lib/github_changelog_generator/generator/generator_generation.rb +0 -180
- data/spec/unit/generator/generator_generation_spec.rb +0 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: cb493bfacf7e5ec521d56e8ac70078b9f2297e88707aaa1adc267fa1f2caa829
|
4
|
+
data.tar.gz: b5368080a19d7b90f36087b1601cffed3034b4e0562e0c57b9bbe519a683cdee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a5482719348a05eec6f1644a9ff8298720e1b33dc34bb7d8ee030e567878285e0b538d17039f8cc23aac5829a9eddeaf96f3d7e5d68b44d3e1ec848c2cbbcffc
|
7
|
+
data.tar.gz: e172b08ad77a2c4d6650441a36bd594dcbc186ab85afc47c382d1ea303927fbed3aae280987e25e264eb92419b75ae3262466a92950653a21b8e1093b120e3dd
|
data/LICENSE
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
The MIT License (MIT)
|
2
|
-
Copyright (c) 2016 Petr Korolev
|
2
|
+
Copyright (c) 2016-2019 Petr Korolev
|
3
3
|
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
5
5
|
|
data/README.md
CHANGED
@@ -1,275 +1,332 @@
|
|
1
|
-
[![Gem Version](https://badge.fury.io/rb/github_changelog_generator.svg)](http://badge.fury.io/rb/github_changelog_generator)
|
2
|
-
[![
|
3
|
-
[![
|
4
|
-
[![
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
- [
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
- [
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
-
|
220
|
-
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
1
|
+
[![Gem Version](https://badge.fury.io/rb/github_changelog_generator.svg)](http://badge.fury.io/rb/github_changelog_generator)
|
2
|
+
[![CircleCI](https://circleci.com/gh/github-changelog-generator/github-changelog-generator.svg?style=svg)](https://circleci.com/gh/github-changelog-generator/github-changelog-generator)
|
3
|
+
[![Inline docs](http://inch-ci.org/github/github-changelog-generator/github-changelog-generator.svg)](http://inch-ci.org/github/github-changelog-generator/github-changelog-generator)
|
4
|
+
[![Join the chat at https://gitter.im/github-changelog-generator/chat](https://badges.gitter.im/github-changelog-generator/chat.svg)](https://gitter.im/github-changelog-generator/chat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
5
|
+
|
6
|
+
# github-changelog-generator ![GitHub Logo](../master/images/logo.jpg)
|
7
|
+
|
8
|
+
<!--
|
9
|
+
To update TOC, please run:
|
10
|
+
> doctoc ./README.md --github
|
11
|
+
-->
|
12
|
+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
13
|
+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
14
|
+
|
15
|
+
|
16
|
+
- [Changelog generation has never been so easy](#changelog-generation-has-never-been-so-easy)
|
17
|
+
- [*What’s the point of a changelog?*](#whats-the-point-of-a-changelog)
|
18
|
+
- [*Why should I care?*](#why-should-i-care)
|
19
|
+
- [Installation](#installation)
|
20
|
+
- [Running with Docker](#running-with-docker)
|
21
|
+
- [Output example](#output-example)
|
22
|
+
- [Usage](#usage)
|
23
|
+
- [Params](#params)
|
24
|
+
- [Params File](#params-file)
|
25
|
+
- [GitHub token](#github-token)
|
26
|
+
- [Migrating from a manual changelog](#migrating-from-a-manual-changelog)
|
27
|
+
- [Rake task](#rake-task)
|
28
|
+
- [Features and advantages of this project](#features-and-advantages-of-this-project)
|
29
|
+
- [Using the summary section feature](#using-the-summary-section-feature)
|
30
|
+
- [Alternatives](#alternatives)
|
31
|
+
- [Projects using this library](#projects-using-this-library)
|
32
|
+
- [Am I missing some essential feature?](#am-i-missing-some-essential-feature)
|
33
|
+
- [FAQ](#faq)
|
34
|
+
- [Contributing](#contributing)
|
35
|
+
- [License](#license)
|
36
|
+
|
37
|
+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
38
|
+
|
39
|
+
|
40
|
+
### Changelog generation has never been so easy
|
41
|
+
|
42
|
+
**Fully automated changelog generation** - This gem generates a changelog file based on **tags**, **issues** and merged **pull requests** (and splits them into separate lists according to labels) from :octocat: GitHub Issue Tracker.
|
43
|
+
|
44
|
+
Since you don't have to fill your `CHANGELOG.md` manually now: just run the script, relax and take a cup of :coffee: before your next release! :tada:
|
45
|
+
|
46
|
+
### *What’s the point of a changelog?*
|
47
|
+
|
48
|
+
To make it easier for users and contributors to see precisely what notable changes have been made between each release (or version) of the project.
|
49
|
+
|
50
|
+
### *Why should I care?*
|
51
|
+
|
52
|
+
Because software tools are for _people_. "Changelogs make it easier for users and
|
53
|
+
contributors to see precisely what notable changes have been made between each
|
54
|
+
release (or version) of the project."
|
55
|
+
|
56
|
+
:arrow_right: *[https://keepachangelog.com](https://keepachangelog.com)*
|
57
|
+
|
58
|
+
## Installation
|
59
|
+
|
60
|
+
GitHub Changelog Generator is a [Ruby](https://www.ruby-lang.org/)
|
61
|
+
program, distributed as a RubyGem. The Ruby language homepage has an [Installation page](https://www.ruby-lang.org/en/documentation/installation/).
|
62
|
+
|
63
|
+
Install the gem like:
|
64
|
+
|
65
|
+
$ gem install github_changelog_generator
|
66
|
+
|
67
|
+
Depending on your system, you _may_ need to run the shell as an Administrator (Windows),
|
68
|
+
or use `sudo gem install github_changelog_generator` (Linux).
|
69
|
+
|
70
|
+
|
71
|
+
## Usage
|
72
|
+
|
73
|
+
|
74
|
+
### Running with CLI:
|
75
|
+
|
76
|
+
github_changelog_generator -u github_project_namespace -p github_project
|
77
|
+
|
78
|
+
(where the project namespace is _likely_ your username if it's a project you own, but it could also be the namespace of the project)
|
79
|
+
|
80
|
+
|
81
|
+
### Running with Docker
|
82
|
+
|
83
|
+
Using [Docker](https://www.docker.com/products/docker-desktop) is an alternative to installing Ruby and the gem.
|
84
|
+
|
85
|
+
Example invocation:
|
86
|
+
|
87
|
+
$ docker run -it --rm -v "$(pwd)":/usr/local/src/your-app ferrarimarco/github-changelog-generator
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
- For Github Enterprise repos, specify *both* `--github-site` and `--github-api` options:
|
92
|
+
|
93
|
+
$ github_changelog_generator --github-site="https://github.yoursite.com" \
|
94
|
+
--github-api="https://github.yoursite.com/api/v3/"
|
95
|
+
|
96
|
+
|
97
|
+
This generates a `CHANGELOG.md`, with pretty Markdown formatting.
|
98
|
+
|
99
|
+
|
100
|
+
## Output example
|
101
|
+
|
102
|
+
- Look at **[CHANGELOG.md](https://github.com/github-changelog-generator/Github-Changelog-Generator/blob/master/CHANGELOG.md)** for this project
|
103
|
+
- [ActionSheetPicker-3.0/CHANGELOG.md](https://github.com/skywinder/ActionSheetPicker-3.0/blob/develop/CHANGELOG.md) was generated by command:
|
104
|
+
|
105
|
+
$ github_changelog_generator -u github-changelog-generator -p ActionSheetPicker-3.0
|
106
|
+
|
107
|
+
- In general, it looks like this:
|
108
|
+
|
109
|
+
> ## [1.2.5](https://github.com/github-changelog-generator/Github-Changelog-Generator/tree/1.2.5) (2015-01-15)
|
110
|
+
>
|
111
|
+
> [Full Changelog](https://github.com/github-changelog-generator/Github-Changelog-Generator/compare/1.2.4...1.2.5)
|
112
|
+
>
|
113
|
+
> **Implemented enhancements:**
|
114
|
+
>
|
115
|
+
> - Use milestone to specify in which version bug was fixed [\#22](https://github.com/github-changelog-generator/Github-Changelog-Generator/issues/22)
|
116
|
+
>
|
117
|
+
> **Fixed bugs:**
|
118
|
+
>
|
119
|
+
> - Error when trying to generate log for repo without tags [\#32](https://github.com/github-changelog-generator/Github-Changelog-Generator/issues/32)
|
120
|
+
>
|
121
|
+
> **Merged pull requests:**
|
122
|
+
>
|
123
|
+
> - PrettyPrint class is included using lowercase 'pp' [\#43](https://github.com/github-changelog-generator/Github-Changelog-Generator/pull/43) ([schwing](https://github.com/schwing))
|
124
|
+
>
|
125
|
+
> - support enterprise github via command line options [\#42](https://github.com/github-changelog-generator/Github-Changelog-Generator/pull/42) ([glenlovett](https://github.com/glenlovett))
|
126
|
+
|
127
|
+
### Params
|
128
|
+
|
129
|
+
Print help for all command-line options to learn more details:
|
130
|
+
|
131
|
+
$ github_changelog_generator --help
|
132
|
+
|
133
|
+
For more details about params, read the Wiki page: [**Advanced changelog generation examples**](https://github.com/github-changelog-generator/github-changelog-generator/wiki/Advanced-change-log-generation-examples)
|
134
|
+
|
135
|
+
### Params File
|
136
|
+
|
137
|
+
In your project root, you can put a params file named `.github_changelog_generator` to override default params:
|
138
|
+
|
139
|
+
Example:
|
140
|
+
|
141
|
+
```
|
142
|
+
unreleased=false
|
143
|
+
future-release=5.0.0
|
144
|
+
since-tag=1.0.0
|
145
|
+
```
|
146
|
+
|
147
|
+
### GitHub token
|
148
|
+
|
149
|
+
GitHub only allows **50 unauthenticated requests per hour**.
|
150
|
+
|
151
|
+
Therefore, it's recommended to run this script with authentication by using a **token**.
|
152
|
+
|
153
|
+
Here's how:
|
154
|
+
|
155
|
+
- [Generate a token here](https://github.com/settings/tokens/new?description=GitHub%20Changelog%20Generator%20token) - you only need "repo" scope for private repositories
|
156
|
+
- Either:
|
157
|
+
- Run the script with `--token <your-40-digit-token>`; **OR**
|
158
|
+
- Set the `CHANGELOG_GITHUB_TOKEN` environment variable to your 40 digit token
|
159
|
+
|
160
|
+
You can set an environment variable by running the following command at the prompt, or by adding it to your shell profile (e.g., `.env`, `~/.bash_profile`, `~/.zshrc`, etc):
|
161
|
+
|
162
|
+
export CHANGELOG_GITHUB_TOKEN="«your-40-digit-github-token»"
|
163
|
+
|
164
|
+
So, if you get a message like this:
|
165
|
+
|
166
|
+
``` markdown
|
167
|
+
API rate limit exceeded for github_username.
|
168
|
+
See: https://developer.github.com/v3/#rate-limiting
|
169
|
+
```
|
170
|
+
|
171
|
+
It's time to create this token! (Or, wait an hour for GitHub to reset your unauthenticated request limit.)
|
172
|
+
|
173
|
+
## Migrating from a manual changelog
|
174
|
+
|
175
|
+
Knowing how dedicated you are to your project, you probably haven't been waiting for `github-changelog-generator` to keep a changelog.
|
176
|
+
But you probably don't want your project's open issues and PRs for all past features listed in your historic changelog, either.
|
177
|
+
|
178
|
+
That's where `--base <your-manual-changelog.md>` comes in handy!
|
179
|
+
This option lets append your old manual changelog to the end of the generated entries.
|
180
|
+
|
181
|
+
If you have a `HISTORY.md` file in your project, it will automatically be picked as the static historical changelog and appended.
|
182
|
+
|
183
|
+
### Rake task
|
184
|
+
|
185
|
+
You love `rake`? We do, too! So, we've made it even easier for you:
|
186
|
+
we've provided a `rake` task library for your changelog generation.
|
187
|
+
|
188
|
+
Configure the task in your `Rakefile`:
|
189
|
+
|
190
|
+
```ruby
|
191
|
+
require 'github_changelog_generator/task'
|
192
|
+
|
193
|
+
GitHubChangelogGenerator::RakeTask.new :changelog do |config|
|
194
|
+
config.user = 'username'
|
195
|
+
config.project = 'project-name'
|
196
|
+
config.since_tag = '0.1.14'
|
197
|
+
config.future_release = '0.2.0'
|
198
|
+
end
|
199
|
+
```
|
200
|
+
|
201
|
+
All command-line options can be passed to the `rake` task as `config`
|
202
|
+
parameters. And since you're naming the `rake` task yourself, you can create
|
203
|
+
as many as you want.
|
204
|
+
|
205
|
+
You can look for params names from the [parser source code (#setup_parser)](https://github.com/github-changelog-generator/github-changelog-generator/blob/master/lib/github_changelog_generator/parser.rb). For example, to translate the bugs label to Portuguese, instead of setting `config.bugs_label`, you have to set `config.bug_prefix`, and so on.
|
206
|
+
|
207
|
+
## Features and advantages of this project
|
208
|
+
|
209
|
+
- Generate canonical, neat changelog file, with default sections that follow [basic changelog guidelines](http://keepachangelog.com) :gem:
|
210
|
+
- Optionally generate **Unreleased** changes (closed issues that have not released yet) :dizzy:
|
211
|
+
- **GitHub Enterprise support** via command line options! :factory:
|
212
|
+
- Flexible format **customization**:
|
213
|
+
- **Customize** issues that **should be added** to changelog :eight_spoked_asterisk:
|
214
|
+
- **Custom date formats** supported (but keep [ISO 8601](http://xkcd.com/1179/) in mind!) :date:
|
215
|
+
- Manually specify the version that fixed an issue (for cases when the issue's Closed date doesn't match) by giving the issue's `milestone` the same name as the tag of version :pushpin:
|
216
|
+
- Automatically **exclude specific issues** that are irrelevant to your changelog (by default, any issue labeled `question`, `duplicate`, `invalid`, or `wontfix`) :scissors:
|
217
|
+
- **Distinguish** issues **by labels**. :mag_right:
|
218
|
+
- Merged pull requests (all merged pull-requests) :twisted_rightwards_arrows:
|
219
|
+
- Bug fixes (issues labeled `bug`) :beetle:
|
220
|
+
- Enhancements (issues labeled `enhancement`) :star2:
|
221
|
+
- Issues (closed issues with no labels) :non-potable_water:
|
222
|
+
|
223
|
+
- Manually include or exclude issues by labels :wrench:
|
224
|
+
- Customize lots more! Tweak the changelog to fit your preferences :tophat:
|
225
|
+
(*See `github_changelog_generator --help` for details)*
|
226
|
+
|
227
|
+
### Using the summary section feature
|
228
|
+
|
229
|
+
For each version, you can add a _release summary_ with text, images, gif animations,
|
230
|
+
etc, and show new features and notes clearly to the user. This is done using GitHub metadata.
|
231
|
+
|
232
|
+
**Example**: adding the release summary for v1.0.0:
|
233
|
+
|
234
|
+
1. Create a new GitHub Issue
|
235
|
+
2. In the Issue's _Description_ field, add your release summary content
|
236
|
+
```
|
237
|
+
![image](https://user-images.githubusercontent.com/12690315/45935880-006a8200-bfeb-11e8-958e-ff742ae66b96.png)
|
238
|
+
|
239
|
+
Hello, World! :tada:
|
240
|
+
```
|
241
|
+
3. Set the Issue Label `release-summary` and add it to the GitHub Milestone `v1.0.0`
|
242
|
+
4. Close the Issue and execute `github-changelog-generator`
|
243
|
+
5. The result looks like this:
|
244
|
+
> ## [v1.0.0](https://github.com/github-changelog-generator/github-changelog-generator/tree/1.0.0) (2014-11-07)
|
245
|
+
> [Full Changelog](https://github.com/github-changelog-generator/github-changelog-generator/compare/0.1.0...1.0.0)
|
246
|
+
>
|
247
|
+
> ![image](https://user-images.githubusercontent.com/12690315/45935880-006a8200-bfeb-11e8-958e-ff742ae66b96.png)
|
248
|
+
>
|
249
|
+
> Hello, World! :tada:
|
250
|
+
>
|
251
|
+
> **Implemented enhancements:**
|
252
|
+
> - Add some features
|
253
|
+
|
254
|
+
### Alternatives
|
255
|
+
|
256
|
+
Here is a [wikipage list of alternatives](https://github.com/github-changelog-generator/Github-Changelog-Generator/wiki/Alternatives) that I found. But none satisfied my requirements.
|
257
|
+
|
258
|
+
*If you know other projects, feel free to edit this Wiki page!*
|
259
|
+
|
260
|
+
|
261
|
+
### Projects using this library
|
262
|
+
|
263
|
+
Here's a [wikipage list of projects](https://github.com/github-changelog-generator/Github-Changelog-Generator/wiki/Projects-using-Github-Changelog-Generator).
|
264
|
+
|
265
|
+
If you've used this project in a live app, please let me know! Nothing makes me happier than seeing someone else take my work and go wild with it.
|
266
|
+
|
267
|
+
*If you are using `github_changelog_generator` to generate your project's changelog, or know of other projects using it, please [add it to this list](https://github.com/github-changelog-generator/github-changelog-generator/wiki/Projects-using-Github-Changelog-Generator).*
|
268
|
+
|
269
|
+
## Am I missing some essential feature?
|
270
|
+
|
271
|
+
- **Nothing is impossible!**
|
272
|
+
|
273
|
+
- Open an [issue](https://github.com/github-changelog-generator/Github-Changelog-Generator/issues/new) and let's make the generator better together!
|
274
|
+
|
275
|
+
- *Bug reports, feature requests, patches, and well-wishes are always welcome.* :heavy_exclamation_mark:
|
276
|
+
|
277
|
+
## FAQ
|
278
|
+
|
279
|
+
- ***I already use GitHub Releases. Why do I need this?***
|
280
|
+
|
281
|
+
GitHub Releases is a very good thing. And it's very good practice to maintain it. (Not a lot of people are using it yet!) :congratulations:
|
282
|
+
|
283
|
+
*BTW: I would like to support GitHub Releases in [next releases](https://github.com/github-changelog-generator/github-changelog-generator/issues/56) ;)*
|
284
|
+
|
285
|
+
I'm not trying to compare the quality of handwritten and auto-generated logs. That said....
|
286
|
+
|
287
|
+
An auto-generated changelog really helps, even if you manually fill in the release notes!
|
288
|
+
|
289
|
+
|
290
|
+
- ***My Ruby version is very old, can I use this?***
|
291
|
+
|
292
|
+
When your Ruby is old, and you don't want to upgrade, and you want to
|
293
|
+
control which libraries you use, you can use Bundler.
|
294
|
+
|
295
|
+
In a Gemfile, perhaps in a non-deployed `:development` group, add this
|
296
|
+
gem:
|
297
|
+
|
298
|
+
```ruby
|
299
|
+
group :development do
|
300
|
+
gem 'github_changelog_generator', require: false
|
301
|
+
end
|
302
|
+
```
|
303
|
+
|
304
|
+
Then you can keep back dependencies like rack, which currently is only
|
305
|
+
compatible with Ruby >= 2.2.2. So, use an older version for your app by
|
306
|
+
adding a line like this to the Gemfile:
|
307
|
+
|
308
|
+
```
|
309
|
+
gem 'rack', '~> 1.6'
|
310
|
+
```
|
311
|
+
|
312
|
+
This way, you can keep on using github_changelog_generator, even if you
|
313
|
+
can't get the latest version of Ruby installed.
|
314
|
+
|
315
|
+
- ***Windows: 1.14.x wants to create a file on an invalid path. Why?***
|
316
|
+
|
317
|
+
Windows: [v1.14.0 introduced a bug where it attempts to create /tmp/github_changelog-logger.log... which isn't a valid path on Windows and thus fails](https://github.com/github-changelog-generator/github-changelog-generator/issues/458)
|
318
|
+
|
319
|
+
Workaround: Create a `C:\tmp`.
|
320
|
+
|
321
|
+
## Contributing
|
322
|
+
|
323
|
+
We have collected notes on how to contribute to this project in [CONTRIBUTING.md].
|
324
|
+
|
325
|
+
[CONTRIBUTING.md]: CONTRIBUTING.md
|
326
|
+
|
327
|
+
## Contact us
|
328
|
+
[Join the chat at gitter : github-changelog-generator](https://gitter.im/github-changelog-generator/chat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
329
|
+
|
330
|
+
## License
|
331
|
+
|
332
|
+
Github Changelog Generator is released under the [MIT License](http://www.opensource.org/licenses/MIT).
|