gemchain 0.2.1 → 0.2.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 +4 -4
- data/CHANGELOG.md +10 -0
- data/lib/gemchain/executor.rb +13 -1
- data/lib/gemchain/version.rb +1 -1
- 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: 7f57089a36952e2778e0ca90654ee97a6484ba1f6f9c002a91c1a30089c6973a
|
|
4
|
+
data.tar.gz: cd1f24b7232ba48c8f1135d8e80374eb656e49e3322d3773b1f3680020761160
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 989b65d9e09fc06ea8445c7137b5e641fd001f7ab332023132a075c91e3a1d7b9649d34470fe78650d2c258507e5f2729d253824d85ec38b082b2efd7121e829
|
|
7
|
+
data.tar.gz: 65efa9a75881d8880d950c2b880816e10d575c9cbf728f427a0679f5fc6fc77c37f41d836a44d5359dbd412b0d8e6bf18db25772c2cae317d37b53dc58dcef1b
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
+
## [0.2.2] — 2026-08-13
|
|
2
|
+
|
|
3
|
+
### Fixed
|
|
4
|
+
|
|
5
|
+
- **Release skips the commit when nothing is staged** — a source gem whose
|
|
6
|
+
version bump was already committed (e.g. a fix shipped together with the
|
|
7
|
+
bump) crashed the cascade with "nothing to commit, working tree clean".
|
|
8
|
+
`:release` now checks for staged changes (`git diff --cached --quiet`)
|
|
9
|
+
and skips the commit while still building, pushing, and tagging.
|
|
10
|
+
|
|
1
11
|
# Changelog
|
|
2
12
|
|
|
3
13
|
## [0.2.1] — 2026-08-12
|
data/lib/gemchain/executor.rb
CHANGED
|
@@ -23,6 +23,13 @@ module Gemchain
|
|
|
23
23
|
detail = out.lines.first(5).join.strip if detail.empty?
|
|
24
24
|
raise ExecutionError, "Command failed: #{command.join(' ')}#{detail.empty? ? '' : "\n#{detail}"}"
|
|
25
25
|
end
|
|
26
|
+
|
|
27
|
+
# Runs a command and reports success without raising. Used for
|
|
28
|
+
# conditional checks (e.g. "are there staged changes?").
|
|
29
|
+
def success?(command, chdir: nil)
|
|
30
|
+
_out, _err, status = Open3.capture3(*command, chdir: chdir)
|
|
31
|
+
status.success?
|
|
32
|
+
end
|
|
26
33
|
end
|
|
27
34
|
|
|
28
35
|
BUMP_LEVELS = %i[patch minor major].freeze
|
|
@@ -170,7 +177,12 @@ module Gemchain
|
|
|
170
177
|
else
|
|
171
178
|
"Bump to #{version} (gemchain)"
|
|
172
179
|
end
|
|
173
|
-
|
|
180
|
+
# Skip the commit when the release's own bump/constraint changes were
|
|
181
|
+
# already committed (e.g. a fix shipped together with the version
|
|
182
|
+
# bump) — `git commit` would fail on a clean tree.
|
|
183
|
+
unless @runner.success?(["git", "diff", "--cached", "--quiet"], chdir: dir)
|
|
184
|
+
@runner.run(["git", "commit", "-m", message], chdir: dir)
|
|
185
|
+
end
|
|
174
186
|
|
|
175
187
|
@runner.run(["gem", "build", "#{name}.gemspec"], chdir: dir)
|
|
176
188
|
@runner.run(["gem", "push", "#{name}-#{version}.gem"], chdir: dir)
|
data/lib/gemchain/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gemchain
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Kaka Ruto
|
|
@@ -109,7 +109,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
109
109
|
- !ruby/object:Gem::Version
|
|
110
110
|
version: '0'
|
|
111
111
|
requirements: []
|
|
112
|
-
rubygems_version: 4.0.
|
|
112
|
+
rubygems_version: 4.0.18
|
|
113
113
|
specification_version: 4
|
|
114
114
|
summary: Cascade gem updates through interdependent gem ecosystems
|
|
115
115
|
test_files: []
|