runger_release_assistant 0.6.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/CHANGELOG.md +3 -0
- data/Gemfile.lock +41 -36
- data/bin/_guard-core +2 -2
- data/bin/guard +2 -2
- data/bin/rspec +2 -2
- data/bin/rubocop +2 -2
- data/lib/runger_release_assistant/version.rb +1 -1
- data/lib/runger_release_assistant.rb +22 -5
- data/runger_release_assistant.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 64d0029dfd4664143185e70ebb80b838eb629e189e75fb51329b630a28235b9b
|
4
|
+
data.tar.gz: 7205aa49c63be1b60af0e9290a40509ae81e94bff0068538f0ce7f8124153cd3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b79cc46effa29a537c0f3b03f06173ee14e9f23b92413fd82d2189ccea24c3e280749643c6d82db5e7d993c7af5d4ea0f2271fa59e4cf0d8572a24f5d1631b41
|
7
|
+
data.tar.gz: 79256d4cca7ee5f90e2fc5b3941231bcb9d4f3429c7a630c1389b7706a94e50e39426884fa6a6500cf121acd31a0cf7ef5a085d3471f690026dcc44d41e0acef
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.3.
|
1
|
+
3.3.3
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
runger_release_assistant (0.
|
4
|
+
runger_release_assistant (0.7.0)
|
5
5
|
activesupport (>= 6, < 8)
|
6
6
|
memo_wise (>= 1.7, < 2)
|
7
7
|
rainbow (>= 3.0, < 4)
|
@@ -10,7 +10,7 @@ PATH
|
|
10
10
|
GEM
|
11
11
|
remote: https://rubygems.org/
|
12
12
|
specs:
|
13
|
-
activesupport (7.1.3)
|
13
|
+
activesupport (7.1.3.3)
|
14
14
|
base64
|
15
15
|
bigdecimal
|
16
16
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
@@ -22,51 +22,52 @@ GEM
|
|
22
22
|
tzinfo (~> 2.0)
|
23
23
|
ast (2.4.2)
|
24
24
|
base64 (0.2.0)
|
25
|
-
bigdecimal (3.1.
|
25
|
+
bigdecimal (3.1.8)
|
26
26
|
byebug (11.1.3)
|
27
27
|
coderay (1.1.3)
|
28
28
|
concurrent-ruby (1.2.3)
|
29
29
|
connection_pool (2.4.1)
|
30
|
-
diff-lcs (1.5.
|
31
|
-
drb (2.2.
|
32
|
-
|
33
|
-
i18n (1.14.1)
|
30
|
+
diff-lcs (1.5.1)
|
31
|
+
drb (2.2.1)
|
32
|
+
i18n (1.14.5)
|
34
33
|
concurrent-ruby (~> 1.0)
|
35
|
-
json (2.7.
|
34
|
+
json (2.7.2)
|
36
35
|
language_server-protocol (3.17.0.3)
|
37
36
|
memo_wise (1.8.0)
|
38
37
|
method_source (1.0.0)
|
39
|
-
minitest (5.
|
38
|
+
minitest (5.23.0)
|
40
39
|
mutex_m (0.2.0)
|
41
40
|
parallel (1.24.0)
|
42
|
-
parser (3.3.0
|
41
|
+
parser (3.3.1.0)
|
43
42
|
ast (~> 2.4.1)
|
44
43
|
racc
|
44
|
+
prism (0.29.0)
|
45
45
|
pry (0.14.2)
|
46
46
|
coderay (~> 1.1)
|
47
47
|
method_source (~> 1.0)
|
48
48
|
pry-byebug (3.10.1)
|
49
49
|
byebug (~> 11.0)
|
50
50
|
pry (>= 0.13, < 0.15)
|
51
|
-
racc (1.
|
51
|
+
racc (1.8.0)
|
52
52
|
rainbow (3.1.1)
|
53
|
-
rake (13.1
|
54
|
-
regexp_parser (2.9.
|
55
|
-
rexml (3.2.
|
56
|
-
|
57
|
-
|
58
|
-
rspec-
|
59
|
-
rspec-
|
60
|
-
|
61
|
-
|
62
|
-
|
53
|
+
rake (13.2.1)
|
54
|
+
regexp_parser (2.9.2)
|
55
|
+
rexml (3.2.8)
|
56
|
+
strscan (>= 3.0.9)
|
57
|
+
rspec (3.13.0)
|
58
|
+
rspec-core (~> 3.13.0)
|
59
|
+
rspec-expectations (~> 3.13.0)
|
60
|
+
rspec-mocks (~> 3.13.0)
|
61
|
+
rspec-core (3.13.0)
|
62
|
+
rspec-support (~> 3.13.0)
|
63
|
+
rspec-expectations (3.13.0)
|
63
64
|
diff-lcs (>= 1.2.0, < 2.0)
|
64
|
-
rspec-support (~> 3.
|
65
|
-
rspec-mocks (3.
|
65
|
+
rspec-support (~> 3.13.0)
|
66
|
+
rspec-mocks (3.13.0)
|
66
67
|
diff-lcs (>= 1.2.0, < 2.0)
|
67
|
-
rspec-support (~> 3.
|
68
|
-
rspec-support (3.
|
69
|
-
rubocop (1.
|
68
|
+
rspec-support (~> 3.13.0)
|
69
|
+
rspec-support (3.13.0)
|
70
|
+
rubocop (1.64.0)
|
70
71
|
json (~> 2.3)
|
71
72
|
language_server-protocol (>= 3.17.0)
|
72
73
|
parallel (~> 1.10)
|
@@ -74,27 +75,31 @@ GEM
|
|
74
75
|
rainbow (>= 2.2.2, < 4.0)
|
75
76
|
regexp_parser (>= 1.8, < 3.0)
|
76
77
|
rexml (>= 3.2.5, < 4.0)
|
77
|
-
rubocop-ast (>= 1.
|
78
|
+
rubocop-ast (>= 1.31.1, < 2.0)
|
78
79
|
ruby-progressbar (~> 1.7)
|
79
80
|
unicode-display_width (>= 2.4.0, < 3.0)
|
80
|
-
rubocop-ast (1.
|
81
|
-
parser (>= 3.
|
81
|
+
rubocop-ast (1.31.3)
|
82
|
+
parser (>= 3.3.1.0)
|
82
83
|
rubocop-capybara (2.20.0)
|
83
84
|
rubocop (~> 1.41)
|
84
85
|
rubocop-factory_bot (2.25.1)
|
85
86
|
rubocop (~> 1.41)
|
86
|
-
rubocop-performance (1.
|
87
|
+
rubocop-performance (1.21.0)
|
87
88
|
rubocop (>= 1.48.1, < 2.0)
|
88
|
-
rubocop-ast (>= 1.
|
89
|
-
rubocop-rspec (2.
|
89
|
+
rubocop-ast (>= 1.31.1, < 2.0)
|
90
|
+
rubocop-rspec (2.29.2)
|
90
91
|
rubocop (~> 1.40)
|
91
92
|
rubocop-capybara (~> 2.17)
|
92
93
|
rubocop-factory_bot (~> 2.22)
|
94
|
+
rubocop-rspec_rails (~> 2.28)
|
95
|
+
rubocop-rspec_rails (2.28.3)
|
96
|
+
rubocop (~> 1.40)
|
93
97
|
ruby-progressbar (1.13.0)
|
94
|
-
|
95
|
-
|
98
|
+
runger_style (2.4.0)
|
99
|
+
prism (>= 0.24.0)
|
96
100
|
rubocop (>= 1.38.0, < 2)
|
97
101
|
slop (4.10.1)
|
102
|
+
strscan (3.1.0)
|
98
103
|
tzinfo (2.0.6)
|
99
104
|
concurrent-ruby (~> 1.0)
|
100
105
|
unicode-display_width (2.5.0)
|
@@ -115,7 +120,7 @@ DEPENDENCIES
|
|
115
120
|
runger_style
|
116
121
|
|
117
122
|
RUBY VERSION
|
118
|
-
ruby 3.3.
|
123
|
+
ruby 3.3.3p89
|
119
124
|
|
120
125
|
BUNDLED WITH
|
121
|
-
2.5.
|
126
|
+
2.5.11
|
data/bin/_guard-core
CHANGED
@@ -17,8 +17,8 @@ if File.file?(bundle_binstub)
|
|
17
17
|
if File.read(bundle_binstub, 300).include?('This file was generated by Bundler')
|
18
18
|
load(bundle_binstub)
|
19
19
|
else
|
20
|
-
abort(
|
21
|
-
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.
|
20
|
+
abort('Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
21
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.')
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
data/bin/guard
CHANGED
@@ -17,8 +17,8 @@ if File.file?(bundle_binstub)
|
|
17
17
|
if File.read(bundle_binstub, 300).include?('This file was generated by Bundler')
|
18
18
|
load(bundle_binstub)
|
19
19
|
else
|
20
|
-
abort(
|
21
|
-
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.
|
20
|
+
abort('Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
21
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.')
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
data/bin/rspec
CHANGED
@@ -17,8 +17,8 @@ if File.file?(bundle_binstub)
|
|
17
17
|
if File.read(bundle_binstub, 300).include?('This file was generated by Bundler')
|
18
18
|
load(bundle_binstub)
|
19
19
|
else
|
20
|
-
abort(
|
21
|
-
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.
|
20
|
+
abort('Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
21
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.')
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
data/bin/rubocop
CHANGED
@@ -17,8 +17,8 @@ if File.file?(bundle_binstub)
|
|
17
17
|
if File.read(bundle_binstub, 300).include?('This file was generated by Bundler')
|
18
18
|
load(bundle_binstub)
|
19
19
|
else
|
20
|
-
abort(
|
21
|
-
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.
|
20
|
+
abort('Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
21
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.')
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
@@ -19,6 +19,16 @@ Dir["#{File.dirname(__FILE__)}/runger_release_assistant/**/*.rb"].each { |file|
|
|
19
19
|
class RungerReleaseAssistant
|
20
20
|
prepend MemoWise
|
21
21
|
|
22
|
+
class UnknownPrimaryBranch < StandardError
|
23
|
+
DEFAULT_MESSAGE = <<~MESSAGE.squish
|
24
|
+
Failed to automatically determine primary branch. Specify it via the `primary_branch` option.
|
25
|
+
MESSAGE
|
26
|
+
|
27
|
+
def initialize(message = DEFAULT_MESSAGE)
|
28
|
+
super
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
22
32
|
DEFAULT_OPTIONS = { git: true, rubygems: false }.freeze
|
23
33
|
|
24
34
|
class << self
|
@@ -114,12 +124,19 @@ class RungerReleaseAssistant
|
|
114
124
|
end
|
115
125
|
|
116
126
|
def switch_to_main
|
117
|
-
execute_command("git checkout #{
|
127
|
+
execute_command("git checkout #{primary_branch}")
|
128
|
+
end
|
129
|
+
|
130
|
+
memo_wise \
|
131
|
+
def primary_branch
|
132
|
+
@options[:primary_branch] ||
|
133
|
+
common_primary_branch_name ||
|
134
|
+
(raise(UnknownPrimaryBranch))
|
118
135
|
end
|
119
136
|
|
120
137
|
memo_wise \
|
121
|
-
def
|
122
|
-
|
138
|
+
def common_primary_branch_name
|
139
|
+
`git branch`.scan(/ (main|master|trunk)$/).dig(0, 0)
|
123
140
|
end
|
124
141
|
|
125
142
|
def update_changelog_for_release
|
@@ -193,8 +210,8 @@ class RungerReleaseAssistant
|
|
193
210
|
end
|
194
211
|
|
195
212
|
def restore_and_abort(exit_code:)
|
196
|
-
if current_branch ==
|
197
|
-
execute_command("git reset --hard origin/#{
|
213
|
+
if current_branch == primary_branch
|
214
|
+
execute_command("git reset --hard origin/#{primary_branch}")
|
198
215
|
end
|
199
216
|
|
200
217
|
if execute_command("git rev-parse v#{next_version}", raise_error: false)
|
@@ -39,5 +39,5 @@ Gem::Specification.new do |spec|
|
|
39
39
|
spec.add_dependency('rainbow', '>= 3.0', '< 4')
|
40
40
|
spec.add_dependency('slop', '~> 4.8')
|
41
41
|
|
42
|
-
spec.required_ruby_version =
|
42
|
+
spec.required_ruby_version = ">= #{File.read('.ruby-version').rstrip}"
|
43
43
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: runger_release_assistant
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Runger
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-06-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -134,14 +134,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
134
134
|
requirements:
|
135
135
|
- - ">="
|
136
136
|
- !ruby/object:Gem::Version
|
137
|
-
version: 3.3.
|
137
|
+
version: 3.3.3
|
138
138
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
139
139
|
requirements:
|
140
140
|
- - ">="
|
141
141
|
- !ruby/object:Gem::Version
|
142
142
|
version: '0'
|
143
143
|
requirements: []
|
144
|
-
rubygems_version: 3.5.
|
144
|
+
rubygems_version: 3.5.11
|
145
145
|
signing_key:
|
146
146
|
specification_version: 4
|
147
147
|
summary: A gem / CLI tool to automate the release process of other gems
|