easy_changelog 0.3.1 → 0.4.0
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 +4 -4
- data/CHANGELOG.md +11 -0
- data/Gemfile.lock +1 -1
- data/lib/easy_changelog/task_options_parser.rb +1 -0
- data/lib/easy_changelog/tasks/changelog.rake +8 -0
- data/lib/easy_changelog/version.rb +1 -1
- data/lib/easy_changelog.rb +4 -4
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2e5a35ebc2e8b1d2cd6a88303e11d89bd312155434ad68d24adada013dd1deba
|
|
4
|
+
data.tar.gz: 3885e8e4b28d9f01ef7237f722a949cd0379997b55d0b0344c3ad42461463ef5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 54436307e42febc97c0aea09201401634fd3709339154b4637794ae20839d787b7ed67442f8ecba7de04d934920f37fc4e0c9ea304687005cef99f027a0fbb26
|
|
7
|
+
data.tar.gz: 214bb6651230552992ea4e3c09ef10cf37d441879a5035fe4bc532ed80edfe608d0e01168a7478554399521eecea3c5e0de8d5c3f01b8d50cd2b2366f86cd711
|
data/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
## master (unreleased)
|
|
4
4
|
|
|
5
|
+
## 0.4.0 (2025-01-22)
|
|
6
|
+
### New features
|
|
7
|
+
|
|
8
|
+
* [#51e9888](https://github.com/ivan05almeida/easy_changelog/commit/51e9888): Allow user option. ([@ivan05almeida][])
|
|
9
|
+
|
|
10
|
+
## 0.3.2 (2025-01-22)
|
|
11
|
+
### Bug fixes
|
|
12
|
+
|
|
13
|
+
* [#002a5fc](https://github.com/ivan05almeida/easy_changelog/commit/002a5fc): Fix tasks not loading environment. ([@ivan05almeida][])
|
|
14
|
+
* [#04cd53b](https://github.com/ivan05almeida/easy_changelog/commit/04cd53b): Fix unreleased content when starting a new changelog. ([@ivan05almeida][])
|
|
15
|
+
|
|
5
16
|
## 0.3.1 (2025-01-22)
|
|
6
17
|
### Bug fixes
|
|
7
18
|
|
data/Gemfile.lock
CHANGED
|
@@ -11,6 +11,7 @@ class EasyChangelog
|
|
|
11
11
|
|
|
12
12
|
opts.banner = "Usage: rake changelog:#{type} [options]"
|
|
13
13
|
|
|
14
|
+
opts.on('-u', '--user=ARG', 'Git Username') { |arg| options[:user] = arg }
|
|
14
15
|
opts.on('-b', '--body=ARG', 'Changelog Body Entry') { |arg| options[:body] = arg }
|
|
15
16
|
opts.on('-r', '--ref-id=ARG', 'Ref ID') { |arg| options[:ref_id] = arg }
|
|
16
17
|
opts.on('-R', '--ref-type=ARG', 'Ref type (issues|pull|commit)') { |arg| options[:ref_type] = arg }
|
|
@@ -4,9 +4,14 @@ require 'easy_changelog'
|
|
|
4
4
|
require 'easy_changelog/task_options_parser'
|
|
5
5
|
|
|
6
6
|
namespace :changelog do
|
|
7
|
+
def environment
|
|
8
|
+
Rake.application['environment'].invoke if Rake::Task.task_defined?('environment')
|
|
9
|
+
end
|
|
10
|
+
|
|
7
11
|
EasyChangelog.configuration.changelog_types.each do |type|
|
|
8
12
|
desc "Create a Changelog entry (#{type})"
|
|
9
13
|
task type do
|
|
14
|
+
environment
|
|
10
15
|
options = EasyChangelog::TaskOptionsParser.parse(type, ARGV)
|
|
11
16
|
options[:type] = type
|
|
12
17
|
|
|
@@ -20,6 +25,7 @@ namespace :changelog do
|
|
|
20
25
|
|
|
21
26
|
desc 'Merge entries and delete them'
|
|
22
27
|
task :merge do
|
|
28
|
+
environment
|
|
23
29
|
raise 'No entries!' unless EasyChangelog.pending?
|
|
24
30
|
|
|
25
31
|
EasyChangelog.merge_and_delete!
|
|
@@ -30,6 +36,7 @@ namespace :changelog do
|
|
|
30
36
|
|
|
31
37
|
desc 'Check for no pending changelog entries'
|
|
32
38
|
task :check_clean do
|
|
39
|
+
environment
|
|
33
40
|
next unless EasyChangelog.pending?
|
|
34
41
|
|
|
35
42
|
puts '*** Pending changelog entries!'
|
|
@@ -39,6 +46,7 @@ namespace :changelog do
|
|
|
39
46
|
|
|
40
47
|
desc 'Add release entry'
|
|
41
48
|
task :release do
|
|
49
|
+
environment
|
|
42
50
|
EasyChangelog.release!
|
|
43
51
|
cmd = "git commit -a -m 'Update Changelog'"
|
|
44
52
|
puts cmd
|
data/lib/easy_changelog.rb
CHANGED
|
@@ -131,12 +131,12 @@ class EasyChangelog
|
|
|
131
131
|
@header = ss.scan_until(EasyChangelog.configuration.unreleased_header)
|
|
132
132
|
unreleased = ss.scan_until(/\n(?=## )/m)
|
|
133
133
|
|
|
134
|
-
if unreleased
|
|
135
|
-
@unreleased = parse_release(unreleased)
|
|
136
|
-
@rest = ss.rest
|
|
137
|
-
else
|
|
134
|
+
if unreleased.nil?
|
|
138
135
|
@unreleased = parse_release(ss.rest)
|
|
139
136
|
@rest = ''
|
|
137
|
+
else
|
|
138
|
+
@unreleased = parse_release(unreleased)
|
|
139
|
+
@rest = ss.rest
|
|
140
140
|
end
|
|
141
141
|
end
|
|
142
142
|
|