releasinator 0.7.1 → 0.7.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/PULL_REQUEST_TEMPLATE.md +7 -0
- data/CHANGELOG.md +4 -0
- data/lib/changelog/validator.rb +5 -18
- data/lib/releasinator/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5b20f93a033357d9693f22a79e902f877bb5fb66
|
4
|
+
data.tar.gz: 12a453a37c9ab3cff00345b7ceb560978724e514
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c901d00a7f8f6177b60a7cf0c309f076f978a5ed988820dbe157b9b9c86e4716f05f8e522baa7704cc00e71d449cc1ef0f2427a93a993b284b99863fa57fb15
|
7
|
+
data.tar.gz: 45f134a7199df5297dc9b4930bba9c1dc3ac271239a375c3169df3e2e096b81a50cb7f1469fb9ed14534ac2c75d988479fe1d493b2657ea0912d1a54a9d61ffd
|
data/CHANGELOG.md
CHANGED
data/lib/changelog/validator.rb
CHANGED
@@ -21,6 +21,7 @@ module Releasinator
|
|
21
21
|
|
22
22
|
newer_version = nil
|
23
23
|
changelog_hash.each do |key,value|
|
24
|
+
|
24
25
|
prefix, version, suffix = key.partition(RELEASE_REGEX)
|
25
26
|
puts "Checking version with prefix:'#{prefix}', version:'#{version}', suffix:'#{suffix}'." if @releasinator_config[:verbose]
|
26
27
|
if prefix != latest_release_prefix
|
@@ -66,24 +67,10 @@ module Releasinator
|
|
66
67
|
end
|
67
68
|
|
68
69
|
def validate_changelog_contents(changelog_contents)
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
# First release!
|
74
|
-
'(^#{RELEASE_REGEX}).*\n----.*',
|
75
|
-
|
76
|
-
# h1/h2 header retrieved from https://github.com/tech-angels/vandamme/#format and modified to skip headers with dots in the name
|
77
|
-
'^#{0,3} ?([\w\d\.-]+\.[\d\.-]+[a-zA-Z0-9])(?: \W (\w+ \d{1,2}(?:st|nd|rd|th)?,\s\d{4}|\d{4}-\d{2}-\d{2}|\w+))?\n?[=-]*'
|
78
|
-
]
|
79
|
-
|
80
|
-
changelog_hash = nil
|
81
|
-
version_header_regexes.each do |version_header_regex|
|
82
|
-
parser = Vandamme::Parser.new(changelog: changelog_contents, version_header_exp: version_header_regex, format: 'markdown')
|
83
|
-
changelog_hash = parser.parse
|
84
|
-
|
85
|
-
break if !changelog_hash.empty?
|
86
|
-
end
|
70
|
+
# Modified version of Vandamme::Parser::DEFAULT_REGEX to disallow versions with leading alpha characters
|
71
|
+
changelog_regex = Regexp.new('^#{0,3} ?([\d\.-]+\.[\w\d\.-]+[a-zA-Z0-9])(?: \W (\w+ \d{1,2}(?:st|nd|rd|th)?,\s\d{4}|\d{4}-\d{2}-\d{2}|\w+))?\n?[=-]*')
|
72
|
+
parser = Vandamme::Parser.new(changelog: changelog_contents, version_header_exp: changelog_regex, format: 'markdown')
|
73
|
+
changelog_hash = parser.parse
|
87
74
|
|
88
75
|
if changelog_hash.empty?
|
89
76
|
Printer.fail("Unable to find any releases in the CHANGELOG.md. Please check that the formatting is correct.")
|
data/lib/releasinator/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: releasinator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- PayPal
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -158,6 +158,7 @@ extensions: []
|
|
158
158
|
extra_rdoc_files: []
|
159
159
|
files:
|
160
160
|
- ".github/ISSUE_TEMPLATE.md"
|
161
|
+
- ".github/PULL_REQUEST_TEMPLATE.md"
|
161
162
|
- ".gitignore"
|
162
163
|
- ".releasinator.rb"
|
163
164
|
- CHANGELOG.md
|