gem_toys 0.10.0 → 0.11.2
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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 112ee3b1f0047eb32d9beedccc1249e000164a10513365de206c8d1bf06a0691
|
4
|
+
data.tar.gz: 9876889866f9d38eeceb03ea04303845088e5fc429e7f8a9e5312dc0a35cce83
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4e6342e7bb1b2485caa3b08a9c0bda86961f47626f7236d808c5bfebd15fb37b4f28021ed43b9faaccd669b9f0b66cd237842301bc28578d48d35d258a3f3b98
|
7
|
+
data.tar.gz: 6ba75096de3694778131890372df8b5ba4fad5a3d3f1386635d6b86f75efa7dae98bda97be352998d246656b271cfcdc3549071a22508424c197a6f7828cc230
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,20 @@
|
|
2
2
|
|
3
3
|
## Unreleased
|
4
4
|
|
5
|
+
## 0.11.2 (2021-11-07)
|
6
|
+
|
7
|
+
* Fix version for gem staff after manual refresh too.
|
8
|
+
|
9
|
+
## 0.11.1 (2021-11-07)
|
10
|
+
|
11
|
+
* Fix new version for git staff after manual refresh.
|
12
|
+
|
13
|
+
## 0.11.0 (2021-10-29)
|
14
|
+
|
15
|
+
* Revert version and changelog files changes at rejection.
|
16
|
+
* Revert version file changes at changelog fails.
|
17
|
+
* Update development dependencies.
|
18
|
+
|
5
19
|
## 0.10.0 (2021-10-15)
|
6
20
|
|
7
21
|
* Process cases with non-JSON String from RubyGems.org.
|
@@ -28,7 +28,10 @@ module GemToys
|
|
28
28
|
|
29
29
|
unreleased_title_index = @changelog_lines.index("#{unreleased_title}\n")
|
30
30
|
|
31
|
-
|
31
|
+
unless unreleased_title_index
|
32
|
+
sh "git restore --worktree #{version_file_path}"
|
33
|
+
abort_without_unreleased_title
|
34
|
+
end
|
32
35
|
|
33
36
|
@changelog_lines.insert(
|
34
37
|
unreleased_title_index + 2,
|
@@ -8,16 +8,17 @@ module GemToys
|
|
8
8
|
private
|
9
9
|
|
10
10
|
def process_git
|
11
|
-
|
11
|
+
## `current_version` should be refreshed before this method invocation
|
12
|
+
version_git_tag = "#{@template.version_tag_prefix}#{current_version}"
|
12
13
|
|
13
14
|
## Checkout to a new git branch, required for protected `master` with CI
|
14
|
-
# sh "git switch -c #{
|
15
|
+
# sh "git switch -c #{version_git_tag}"
|
15
16
|
|
16
17
|
commit_changes
|
17
18
|
|
18
19
|
## Tag commit
|
19
20
|
puts 'Tagging the commit...'
|
20
|
-
sh "git tag -a #{
|
21
|
+
sh "git tag -a #{version_git_tag} -m 'Version #{current_version}'"
|
21
22
|
|
22
23
|
## Push commit
|
23
24
|
puts 'Pushing commit...'
|
@@ -33,7 +34,7 @@ module GemToys
|
|
33
34
|
|
34
35
|
sh "git add #{version_file_path} #{changelog_file_path}"
|
35
36
|
|
36
|
-
sh "git commit -m 'Update version to #{
|
37
|
+
sh "git commit -m 'Update version to #{current_version}'"
|
37
38
|
end
|
38
39
|
end
|
39
40
|
end
|
@@ -76,8 +76,6 @@ module GemToys
|
|
76
76
|
else
|
77
77
|
new_version
|
78
78
|
end
|
79
|
-
|
80
|
-
clear_memery_cache! :current_version
|
81
79
|
end
|
82
80
|
|
83
81
|
def handle_keyword_in_new_version(current_version_parts, version_index)
|
@@ -119,14 +117,23 @@ module GemToys
|
|
119
117
|
|
120
118
|
menu.prompt = 'Are these changes correct? '
|
121
119
|
|
122
|
-
menu.choice(:yes)
|
123
|
-
|
120
|
+
menu.choice(:yes) do
|
121
|
+
## `current_version` is using in `git` and `gem` commands
|
122
|
+
clear_memery_cache! :current_version
|
123
|
+
end
|
124
|
+
menu.choice(:no) { handle_refusing_to_continue }
|
124
125
|
menu.choice(:refresh) do
|
125
|
-
handle_new_version
|
126
126
|
wait_for_manual_check
|
127
127
|
end
|
128
128
|
end
|
129
129
|
end
|
130
|
+
|
131
|
+
def handle_refusing_to_continue
|
132
|
+
[version_file_path, changelog_file_path].each do |file_path|
|
133
|
+
sh "git restore --worktree #{file_path}"
|
134
|
+
end
|
135
|
+
abort
|
136
|
+
end
|
130
137
|
end
|
131
138
|
end
|
132
139
|
end
|
data/lib/gem_toys/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gem_toys
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Popov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-11-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: alt_memery
|
@@ -156,14 +156,14 @@ dependencies:
|
|
156
156
|
requirements:
|
157
157
|
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: 1.
|
159
|
+
version: 1.22.2
|
160
160
|
type: :development
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: 1.
|
166
|
+
version: 1.22.2
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
168
|
name: rubocop-performance
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|