github_changelog_generator 1.3.10 → 1.3.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 550ffaa5315e62e51fff66f6849d613645cd2b66
4
- data.tar.gz: 90f49fbb710335783ab9c1c8000942964b278432
3
+ metadata.gz: fefe14e9cd57e2e1be74ebe9d3f178674935cdd8
4
+ data.tar.gz: dac594490d8eb0a565c7ef1f628955e8af2aee05
5
5
  SHA512:
6
- metadata.gz: b8be22cfb5f754d1a9e5c0db864242bb1dfeca8ddf0d39feea9ba0e176210762cee0161756ede317675deaa36a1f33c154189f61bae21a652d6a1ecd33290745
7
- data.tar.gz: fb3b6feb084be5f671389199d7234c75039eb411bcf74b44460597bc4323bbba6309d9b64d4ba927cadda0eb980c9f603e2ea802e11fb648e738b414998d05ba
6
+ metadata.gz: c9568c263c416e7dbcce25ce33fe34ce410ebc2bea82147299a9c7e28f78145d58d0d5434d1cb8200b50bc84372b8a7ff60a60f17ab8c7bb4e35598b2e16405e
7
+ data.tar.gz: 5c76d242b1b96bcc1f63aa7af0dadf379f650eb96bda90dda19b037b68560bf251a72959fe9ef9e8b4235160768795fe51e29b4072a213978ce0d0777be878db
@@ -1,5 +1,17 @@
1
1
  # Change Log
2
2
 
3
+ ## [1.3.10](https://github.com/skywinder/Github-Changelog-Generator/tree/1.3.10) (2015-03-18)
4
+
5
+ [Full Changelog](https://github.com/skywinder/Github-Changelog-Generator/compare/1.3.9...1.3.10)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - Exclude closed PR's from changelog. [\#69](https://github.com/skywinder/Github-Changelog-Generator/issues/69)
10
+
11
+ **Merged pull requests:**
12
+
13
+ - Fix termination in case of empty unreleased section with `--unreleased-only` option. [\#70](https://github.com/skywinder/Github-Changelog-Generator/pull/70) ([skywinder](https://github.com/skywinder))
14
+
3
15
  ## [1.3.9](https://github.com/skywinder/Github-Changelog-Generator/tree/1.3.9) (2015-03-06)
4
16
 
5
17
  [Full Changelog](https://github.com/skywinder/Github-Changelog-Generator/compare/1.3.8...1.3.9)
@@ -10,7 +22,7 @@
10
22
 
11
23
  **Merged pull requests:**
12
24
 
13
- - Concurrency problem in case of issues \> 2048 [\#65](https://github.com/skywinder/Github-Changelog-Generator/pull/65) ([skywinder](https://github.com/skywinder))
25
+ - Resolved concurrency problem in case of issues \> 2048 [\#65](https://github.com/skywinder/Github-Changelog-Generator/pull/65) ([skywinder](https://github.com/skywinder))
14
26
 
15
27
  ## [1.3.8](https://github.com/skywinder/Github-Changelog-Generator/tree/1.3.8) (2015-03-05)
16
28
 
data/README.md CHANGED
@@ -1,8 +1,7 @@
1
-
2
1
  [![Gem Version](https://badge.fury.io/rb/github_changelog_generator.svg)](http://badge.fury.io/rb/github_changelog_generator)
3
- [![Build Status](https://travis-ci.org/skywinder/Github-Changelog-Generator.svg?branch=master)](https://travis-ci.org/skywinder/Github-Changelog-Generator)
2
+ [![Build Status](https://travis-ci.org/skywinder/github-changelog-generator.svg?branch=master)](https://travis-ci.org/skywinder/github-changelog-generator)
4
3
 
5
- GitHub Changelog Generator
4
+ GitHub Changelog Generator ![GitHub Logo](../master/images/logo.jpg)
6
5
  ==================
7
6
 
8
7
  - [Installation](#installation)
@@ -13,14 +12,23 @@ GitHub Changelog Generator
13
12
  - [Features and advantages of this project](#features-and-advantages-of-this-project)
14
13
  - [Alternatives](#alternatives)
15
14
  - [Projects using this library](#projects-using-this-library)
16
- - [Am I missed some essential feature?](#am-i-missed-some-essential-feature)
15
+ - [Am I missing some essential feature?](#am-i-missing-some-essential-feature)
17
16
  - [Contributing](#contributing)
18
17
  - [License](#license)
19
18
 
20
19
 
21
- Changelog generation has never been so easy.
20
+ ### Changelog generation has never been so easy:
21
+
22
+ **Fully automate changelog generation** - This gem generates change log file based on **tags**, **issues** and merged **pull requests** (and splits them into separate lists according labels) from :octocat: GitHub Issue Tracker.
23
+
24
+ Since now you don't have to fill your `CHANGELOG.md` manually: just run the script, relax and take a cup of :coffee: before your next release! :tada:
22
25
 
23
- **Fully automate changelog generation** - This gem generate change log file based on tags, issues and merged pull requests from **Github issue tracker**. This generator complies all [change log format guidelines](http://keepachangelog.com/).
26
+ >### *What’s the point of a change log?*
27
+ 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.
28
+ ### *Why should I care?*
29
+ Because software tools are for people. If you don’t care, why are you contributing to open source? Surely, there must be a kernel (ha!) of care somewhere in that lovely little brain of yours.
30
+
31
+ > :copyright: *[http://keepachangelog.com](http://keepachangelog.com/)*
24
32
 
25
33
  ## Installation
26
34
 
@@ -57,7 +65,7 @@ Changelog generation has never been so easy.
57
65
  ## Usage
58
66
  **It's really simple**:
59
67
 
60
- - If your **git remote** `origin` refer to your GitHub repo, then just go to your project folder and run:
68
+ - If your **git remote** `origin` refers to your GitHub repo, then just go to your project folder and run:
61
69
 
62
70
  github_changelog_generator
63
71
 
@@ -96,7 +104,7 @@ Type `github_changelog_generator --help` for detailed usage.
96
104
 
97
105
  ### GitHub token
98
106
 
99
- Since GitHub allow to make only 50 requests without authentication it's recommended to run this script with token
107
+ Since GitHub allows you to make only 50 requests without authentication it's recommended to run this script with a token (`-t, --token` option)
100
108
 
101
109
  **You can easily [generate it here](https://github.com/settings/applications)**.
102
110
 
@@ -115,23 +123,27 @@ So, if you got error like this:
115
123
  It's time to create this token or wait for 1 hour before GitHub reset the counter for your IP.
116
124
 
117
125
  ##Features and advantages of this project
118
- - Generate canonical change log file, followed by [keepachangelog.com guidlines](http://keepachangelog.com/)
119
- - Possible to generate **Unreleased** changes (closed issues that have not released yet)
120
- - **GitHub Enterprise support** via command line options!
126
+ - Generate canonical, neat change log file, followed by [basic change log guidlines](http://keepachangelog.com/) :gem:
127
+ - Possible to generate **Unreleased** changes (closed issues that have not released yet) :dizzy:
128
+ - **GitHub Enterprise support** via command line options! :factory:
121
129
  - Flexible format **customisation**:
122
- - **Customize** issues, that **should be added** to changelog
123
- - **Custom date format** supported
124
- - Ability to manually specify in which version issue was fixed (in case, when closed date is not match) by setting `milestone` of issue the same name as tag of required version
125
- - Ability to **exclude specific issues** from change log (by labels)
126
- - **Automatically exclude "questions"** - issues marked as `question` labels (and other issues, that shouldn't be in change log file: with `duplicate invalid wontfix` labels)
127
- - **Distinguish** bug fixes, enchantments, and closed issues **according labels**.
128
- - Issues (closed issues w/o any labels)
129
- - Merged pull-requests (all merged pull-requests)
130
- - Bug-fixes (by label `bug` in issue)
131
- - Enhancements (by label `enhancement` in issue)
130
+ - **Customize** issues, that **should be added** to changelog :eight_spoked_asterisk:
131
+ - **Custom date format** supported (but get in mind [ISO 8601](http://xkcd.com/1179/) ) :date:
132
+ - Ability to manually specify in which version issue was fixed (in case, when closed date is not match) by setting `milestone` of issue the same name as tag of required version :pushpin:
133
+ - Automatically **exclude specific issues**, not-related to change log (any issue, that has label `question` `duplicate` `invalid` `wontfix`by default) :scissors:
134
+ - **Distinguish** issues **according labels**. :mag_right:
135
+ - Merged pull requests (all `merged` pull-requests) :twisted_rightwards_arrows:
136
+ - Bug fixes (by label `bug` in issue) :beetle:
137
+ - Enhancements (by label `enhancement` in issue) :star2:
138
+ - Issues (closed issues `w/o any labels`) :non-potable_water:
139
+
140
+ - You can manually set which labels should be included/excluded. :wrench:
141
+ - Apply a lot of other customisations, to fit changelog for your personal style :tophat:
142
+ (*look `github_changelog_generator --help` for details)*
143
+
132
144
 
133
145
  ###Alternatives
134
- Here is a [wikipage list of alternatives](https://github.com/skywinder/Github-Changelog-Generator/wiki/Alternatives), that I found. But no one was satisfy my requirements.
146
+ Here is a [wikipage list of alternatives](https://github.com/skywinder/Github-Changelog-Generator/wiki/Alternatives), that I found. But none satisfied my requirements.
135
147
 
136
148
  *If you know other projects - feel free to edit this Wiki page!*
137
149
 
@@ -141,13 +153,38 @@ Here is a [wikipage list of alternatives](https://github.com/skywinder/Github-Ch
141
153
 
142
154
  *If you are using `github_changelog_generator` for generation change log in your project or know another project that uses it, please add it to [this] (https://github.com/skywinder/Github-Changelog-Generator/wiki/Projects-using-Github-Changelog-Generator) list.*
143
155
 
144
- ## Am I missed some essential feature?
156
+ ## Am I missing some essential feature?
157
+
158
+ - **Nothing is impossible!**
159
+
160
+ - Open an [issue](https://github.com/skywinder/Github-Changelog-Generator/issues/new) and let's make generator better together!
161
+
162
+ - *Bug reports, feature requests, patches, well-wishes are always welcome* :heavy_exclamation_mark:
163
+
164
+ ## FAQ
165
+
166
+ - ***I already use GitHub Releases. Why do I need this?***
167
+
168
+ GitHub Releases is a very good thing. And it's very good practice to maintain it (not so much people using it yet)! :congratulations:
169
+
170
+ *BDW: I would like to support GitHub Releases in [next releases](https://github.com/skywinder/github-changelog-generator/issues/56) ;)*
171
+
172
+ I'm not try to compare quality of auto-generated and manually generated logs.. but:
173
+
174
+ The auto generated Changelog really helps even if you manually fill Releases notes!
175
+
176
+ For example:
177
+
178
+ When I found a closed bug - it's very useful to understand, in which release it was fixed. In that case you can easily find this issue by \# in `CHANGELOG.md`.
145
179
 
146
- **Nothing is impossible!**
180
+ - it's not so quite easy to find it in manually filled Releases notes.
181
+ - this file can also help you to build your Release note and not miss features in manually-filled list.
147
182
 
148
- Open an [issue](https://github.com/skywinder/Github-Changelog-Generator/issues/new) and let's make generator better together!
183
+ In the end:
149
184
 
150
- *Bug reports, feature requests, patches, well-wishes are always welcome!*
185
+ I think, that GitHub Releases is more for end-users.
186
+ But `CHANGELOG.md` could stay in the repo for developers with detailed list of changes.
187
+ And it's nothing bad to combine GitHub Releases and `CHANGELOG.md` file together in that manner.
151
188
 
152
189
  ## Contributing
153
190
 
@@ -157,6 +194,7 @@ Open an [issue](https://github.com/skywinder/Github-Changelog-Generator/issues/n
157
194
  4. Commit your changes (`git commit -am 'Add some feature'`)
158
195
  5. Push to the branch (`git push origin my-new-feature`)
159
196
  6. Create a new Pull Request
197
+ 7. Profit! :white_check_mark:
160
198
 
161
199
  ## License
162
200
 
Binary file
@@ -27,7 +27,11 @@ module GitHubChangelogGenerator
27
27
  github_options[:endpoint] = options[:github_endpoint] unless options[:github_endpoint].nil?
28
28
  github_options[:site] = options[:github_endpoint] unless options[:github_site].nil?
29
29
 
30
- @github = Github.new github_options
30
+ begin
31
+ @github = Github.new github_options
32
+ rescue
33
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
34
+ end
31
35
 
32
36
  @generator = Generator.new(@options)
33
37
 
@@ -88,7 +92,11 @@ module GitHubChangelogGenerator
88
92
  issue[:actual_date] = issue[:closed_at]
89
93
  else
90
94
  begin
91
- commit = @github.git_data.commits.get @options[:user], @options[:project], event[:commit_id]
95
+ begin
96
+ commit = @github.git_data.commits.get @options[:user], @options[:project], event[:commit_id]
97
+ rescue
98
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
99
+ end
92
100
  issue[:actual_date] = commit[:author][:date]
93
101
  rescue
94
102
  puts "Warning: can't fetch commit #{event[:commit_id]} probably it referenced from another repo."
@@ -110,16 +118,22 @@ module GitHubChangelogGenerator
110
118
  if @options[:verbose]
111
119
  print "Fetching merged dates...\r"
112
120
  end
113
- response = @github.pull_requests.list @options[:user], @options[:project], :state => 'closed'
114
-
115
121
  pull_requests = []
116
- page_i = 0
117
- response.each_page do |page|
118
- page_i += PER_PAGE_NUMBER
119
- count_pages = response.count_pages
120
- print "Fetching merged dates... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
121
- pull_requests.concat(page)
122
- end
122
+ begin
123
+ response = @github.pull_requests.list @options[:user], @options[:project], :state => 'closed'
124
+ page_i = 0
125
+ response.each_page do |page|
126
+ page_i += PER_PAGE_NUMBER
127
+ count_pages = response.count_pages
128
+ print "Fetching merged dates... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
129
+ pull_requests.concat(page)
130
+ end
131
+ rescue
132
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
133
+ end
134
+
135
+
136
+
123
137
  print " \r"
124
138
 
125
139
  @pull_requests.each { |pr|
@@ -276,7 +290,11 @@ module GitHubChangelogGenerator
276
290
  end
277
291
 
278
292
  def is_megred(number)
279
- @github.pull_requests.merged? @options[:user], @options[:project], number
293
+ begin
294
+ @github.pull_requests.merged? @options[:user], @options[:project], number
295
+ rescue
296
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
297
+ end
280
298
  end
281
299
 
282
300
  def get_all_tags
@@ -285,20 +303,26 @@ module GitHubChangelogGenerator
285
303
  print "Fetching tags...\r"
286
304
  end
287
305
 
288
- response = @github.repos.tags @options[:user], @options[:project]
289
-
290
306
  tags = []
291
- page_i = 0
292
- count_pages = response.count_pages
293
- response.each_page do |page|
294
- page_i += PER_PAGE_NUMBER
295
- print "Fetching tags... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
296
- tags.concat(page)
297
- end
298
- print " \r"
299
- if @options[:verbose]
300
- puts "Found #{tags.count} tags"
301
- end
307
+
308
+ begin
309
+ response = @github.repos.tags @options[:user], @options[:project]
310
+ page_i = 0
311
+ count_pages = response.count_pages
312
+ response.each_page do |page|
313
+ page_i += PER_PAGE_NUMBER
314
+ print "Fetching tags... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
315
+ tags.concat(page)
316
+ end
317
+ print " \r"
318
+ if @options[:verbose]
319
+ puts "Found #{tags.count} tags"
320
+ end
321
+ rescue
322
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
323
+ end
324
+
325
+
302
326
 
303
327
  tags
304
328
  end
@@ -512,7 +536,11 @@ module GitHubChangelogGenerator
512
536
  return @tag_times_hash[tag_name['name']]
513
537
  end
514
538
 
515
- github_git_data_commits_get = @github.git_data.commits.get @options[:user], @options[:project], tag_name['commit']['sha']
539
+ begin
540
+ github_git_data_commits_get = @github.git_data.commits.get @options[:user], @options[:project], tag_name['commit']['sha']
541
+ rescue
542
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
543
+ end
516
544
  time_string = github_git_data_commits_get['committer']['date']
517
545
  @tag_times_hash[tag_name['name']] = Time.parse(time_string)
518
546
  end
@@ -558,17 +586,22 @@ module GitHubChangelogGenerator
558
586
  if @options[:verbose]
559
587
  print "Fetching closed issues...\r"
560
588
  end
589
+ issues = []
590
+
591
+ begin
592
+ response = @github.issues.list user: @options[:user], repo: @options[:project], state: 'closed', filter: 'all', labels: nil
593
+ page_i = 0
594
+ count_pages = response.count_pages
595
+ response.each_page do |page|
596
+ page_i += PER_PAGE_NUMBER
597
+ print "Fetching issues... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
598
+ issues.concat(page)
599
+ end
600
+ rescue
601
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
602
+ end
561
603
 
562
- response = @github.issues.list user: @options[:user], repo: @options[:project], state: 'closed', filter: 'all', labels: nil
563
604
 
564
- issues = []
565
- page_i = 0
566
- count_pages = response.count_pages
567
- response.each_page do |page|
568
- page_i += PER_PAGE_NUMBER
569
- print "Fetching issues... #{page_i}/#{count_pages * PER_PAGE_NUMBER}\r"
570
- issues.concat(page)
571
- end
572
605
 
573
606
  print " \r"
574
607
 
@@ -610,7 +643,11 @@ module GitHubChangelogGenerator
610
643
  issues.each_slice(max_thread_number) { |issues_slice|
611
644
  issues_slice.each { |issue|
612
645
  threads << Thread.new {
613
- obj = @github.issues.events.list user: @options[:user], repo: @options[:project], issue_number: issue['number']
646
+ begin
647
+ obj = @github.issues.events.list user: @options[:user], repo: @options[:project], issue_number: issue['number']
648
+ rescue
649
+ puts "Warning: GitHub API rate limit exceed (5000 per hour), change log may not contain some issues.".yellow
650
+ end
614
651
  issue[:events] = obj.body
615
652
  print "Fetching events for issues and PR: #{i+1}/#{@issues.count + @pull_requests.count}\r"
616
653
  i +=1
@@ -1,3 +1,3 @@
1
1
  module GitHubChangelogGenerator
2
- VERSION = '1.3.10'
2
+ VERSION = '1.3.11'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: github_changelog_generator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.10
4
+ version: 1.3.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Petr Korolev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-18 00:00:00.000000000 Z
11
+ date: 2015-03-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -85,6 +85,7 @@ files:
85
85
  - bin/github_changelog_generator
86
86
  - bump_gemfile.rb
87
87
  - github_changelog_generator.gemspec
88
+ - images/logo.jpg
88
89
  - lib/CHANGELOG.md
89
90
  - lib/github_changelog_generator.rb
90
91
  - lib/github_changelog_generator/generator.rb
@@ -110,7 +111,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
110
111
  version: '0'
111
112
  requirements: []
112
113
  rubyforge_project:
113
- rubygems_version: 2.4.4
114
+ rubygems_version: 2.4.3
114
115
  signing_key:
115
116
  specification_version: 4
116
117
  summary: Script, that automatically generate changelog from your tags, issues, labels