changelogerator 0.0.9 → 0.0.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/changelogerator.rb +8 -6
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15c0df34a0b84def4982a8245b7d2fea66d52092941ecfcf761b5c55173670d8
|
4
|
+
data.tar.gz: c196735034e5aedbbff42ef8b8d822c434baed96c518ad6bedc8f6f61f864fbd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb8aaaa63b3cea0adc294b6f02a8a21cffdd7dc52e9ef0c3cf4ee46ea06e30535229c8b9a738b03369fb8b87775169c29c4bf46580b97ceba786483849711ded
|
7
|
+
data.tar.gz: 35952f39e680721b3405aed8d7ce30947c6fc92e41d86942a6fc580a3d856af4ee8682aa8d6b56f7a9d903693346ecfd71e086f59fd7f360730a89a1aba15504
|
data/lib/changelogerator.rb
CHANGED
@@ -16,22 +16,22 @@ class Changelog
|
|
16
16
|
@priorities = [
|
17
17
|
{
|
18
18
|
priority: 1,
|
19
|
-
label: 'C1-low',
|
19
|
+
label: 'C1-low 📌',
|
20
20
|
text: 'Upgrade priority: **Low** (upgrade at your convenience)'
|
21
21
|
},
|
22
22
|
{
|
23
23
|
priority: 3,
|
24
|
-
label: 'C3-medium',
|
24
|
+
label: 'C3-medium 📣',
|
25
25
|
text: 'Upgrade priority: **Medium** (timely upgrade recommended)'
|
26
26
|
},
|
27
27
|
{
|
28
28
|
priority: 7,
|
29
|
-
label: 'C7-high',
|
29
|
+
label: 'C7-high ❗️',
|
30
30
|
text: 'Upgrade priority:❗ **HIGH** ❗ Please upgrade your node as soon as possible'
|
31
31
|
},
|
32
32
|
{
|
33
33
|
priority: 9,
|
34
|
-
label: 'C9-critical',
|
34
|
+
label: 'C9-critical ‼️',
|
35
35
|
text: 'Upgrade priority: ❗❗ **URGENT** ❗❗ PLEASE UPGRADE IMMEDIATELY'
|
36
36
|
}
|
37
37
|
]
|
@@ -95,12 +95,12 @@ class Changelog
|
|
95
95
|
end
|
96
96
|
|
97
97
|
def add(change)
|
98
|
-
changes.prepend(apply_priority_to_change(change))
|
98
|
+
changes.prepend(prettify_title(apply_priority_to_change(change)))
|
99
99
|
end
|
100
100
|
|
101
101
|
def add_from_id(id)
|
102
102
|
pull = @gh.pull_request(@repo, id)
|
103
|
-
add
|
103
|
+
add pull
|
104
104
|
end
|
105
105
|
|
106
106
|
private
|
@@ -109,6 +109,8 @@ class Changelog
|
|
109
109
|
@priorities.each do |p|
|
110
110
|
change[:priority] = p if change[:labels].any? { |l| l[:name] == p[:label] }
|
111
111
|
end
|
112
|
+
# Failsafe: add lowest priority if none detected
|
113
|
+
change[:priority] ||= @priorities[0]
|
112
114
|
change
|
113
115
|
end
|
114
116
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: changelogerator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Martin Pugh
|
@@ -64,7 +64,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
64
64
|
- !ruby/object:Gem::Version
|
65
65
|
version: '0'
|
66
66
|
requirements: []
|
67
|
-
rubygems_version: 3.
|
67
|
+
rubygems_version: 3.1.2
|
68
68
|
signing_key:
|
69
69
|
specification_version: 4
|
70
70
|
summary: Changelog generation/management
|