chandler 0.3.0 → 0.3.1

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: 398cbe68165973df214ecab27511bd1106fb5bb8
4
- data.tar.gz: 39c487db62d4509506244a81a11a90209cf708eb
3
+ metadata.gz: 5fa6bde6eefdf5eb7da60565d059652a41419a66
4
+ data.tar.gz: 660151c83e5e62f1f545b867c8677aac01183ea8
5
5
  SHA512:
6
- metadata.gz: cc683632e858adf5b58ed2a99671736b962695c4d78a4e7cf054ffd673875c4768b858edda5379a9cc24549c9d7ef5bc93784c52be6f64391c19d99a271091da
7
- data.tar.gz: 7069bf9cff51aed51e74624924e9d17b6a0ed2a5bdeaa822cc17682c98bfb850b6789a06ea3dd99dc4a7d78fdb72f5a8728f364578a5b28f5b44ed0d466c2844
6
+ metadata.gz: 4ee9deb4e9b2cf36b8a1b776f635c13256c4b77031a499f4fe5c99025609ad99741c51103d2d002812ee1061fdbcd6619969a9818e0b9d119b9c18e7c0661484
7
+ data.tar.gz: 38f701c602f09f1810dccdd03b7d120948940e83cad2b644c56c37badf00cc727fe4e40a20720c17bc327ad9fe529c0b364f5c234dc4af4b7747d9ecbde5de34
@@ -8,6 +8,12 @@ chandler is in a pre-1.0 state. This means that its APIs and behavior are subjec
8
8
 
9
9
  * Your contribution here!
10
10
 
11
+ ## [0.3.1][] (2016-05-13)
12
+
13
+ * Fix a bug where the formatting of certain Markdown release notes were
14
+ inadvertently altered due to stripping indentation off the first line of the
15
+ text.
16
+
11
17
  ## [0.3.0][] (2016-03-22)
12
18
 
13
19
  * Support Markdown "setext" style h1-level headings [#11](https://github.com/mattbrictson/chandler/pull/11)
@@ -32,7 +38,8 @@ chandler is in a pre-1.0 state. This means that its APIs and behavior are subjec
32
38
  * Initial release
33
39
 
34
40
  [Semver]: http://semver.org
35
- [Unreleased]: https://github.com/mattbrictson/chandler/compare/v0.3.0...HEAD
41
+ [Unreleased]: https://github.com/mattbrictson/chandler/compare/v0.3.1...HEAD
42
+ [0.3.1]: https://github.com/mattbrictson/chandler/compare/v0.3.0...v0.3.1
36
43
  [0.3.0]: https://github.com/mattbrictson/chandler/compare/v0.2.0...v0.3.0
37
44
  [0.2.0]: https://github.com/mattbrictson/chandler/compare/v0.1.2...v0.2.0
38
45
  [0.1.2]: https://github.com/mattbrictson/chandler/compare/v0.1.1...v0.1.2
@@ -57,11 +57,19 @@ module Chandler
57
57
 
58
58
  def changelog_version_and_notes_for_tag(tag)
59
59
  version = tag_mapper.call(tag)
60
- [version, changelog.fetch(version).strip]
60
+ notes = strip_surrounding_empty_lines(changelog.fetch(version))
61
+ [version, notes]
61
62
  rescue Chandler::Changelog::NoMatchingVersion
62
63
  info("Skip #{tag} (no #{version} entry in #{changelog.basename})".gray)
63
64
  nil
64
65
  end
66
+
67
+ # Returns a new string with leading and trailing empty lines removed. A
68
+ # line is empty if it is zero-length or contains only whitespace.
69
+ def strip_surrounding_empty_lines(str)
70
+ str.sub(/\A[[:space:]]*^/, "")
71
+ .sub(/$[[:space:]]*\z/, "")
72
+ end
65
73
  end
66
74
  end
67
75
  end
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Chandler
3
- VERSION = "0.3.0".freeze
3
+ VERSION = "0.3.1".freeze
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chandler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Brictson
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-03-22 00:00:00.000000000 Z
11
+ date: 2016-05-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: netrc
@@ -194,7 +194,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
194
194
  version: '0'
195
195
  requirements: []
196
196
  rubyforge_project:
197
- rubygems_version: 2.6.2
197
+ rubygems_version: 2.6.4
198
198
  signing_key:
199
199
  specification_version: 4
200
200
  summary: Syncs CHANGELOG entries to GitHub's release notes