discharger 0.5.2 → 0.5.3
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 -2
- data/README.md +2 -0
- data/lib/discharger/task.rb +22 -2
- data/lib/discharger/version.rb +1 -1
- 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: 58e5455131987b71212f1b811a6ca1ff705569aefe0421a443ee1c1cd3c2206d
|
|
4
|
+
data.tar.gz: 401267e06fc26b8ce0400351c0d6aac224293b776b4e36cf869e03e59a590722
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b2485f46135afe93dd8e5dbf6ced35fe36162ce9935e24493f4bf1235227be9c62661803fd67d2bbeac0f92d54e020fbdf529e3a89249c84a3e79f6b5462301a
|
|
7
|
+
data.tar.gz: fb0ff615d06f897c89a222311e2e9e78c3883cf3ed275f72059051a426b8ab91343813fe012a606c23a1faf7fc9d9cbf0ef155936cb65a6febea7121a32fc171
|
data/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,17 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
|
6
6
|
and this project adheres to [Semantic Versioning](http://semver.org/).
|
|
7
7
|
|
|
8
|
+
## [0.5.3] - 2026-10-08
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- DISCHARGER_RELEASE_CONFIRM=1 skips the release confirmation prompt (4ff1cc8)
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- release tasks abort with instructions instead of crashing when stdin is closed (4ff1cc8)
|
|
17
|
+
- release:prepare removes its finish branch when you stop at the confirm prompt (64ba2f5)
|
|
18
|
+
|
|
8
19
|
## [0.5.2] - 2026-10-05
|
|
9
20
|
|
|
10
21
|
### Added
|
|
@@ -23,5 +34,3 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
|
|
|
23
34
|
### Fixed
|
|
24
35
|
|
|
25
36
|
- gh calls in setup time out after 15s instead of hanging (e7d7620)
|
|
26
|
-
|
|
27
|
-
## [0.5.1] - 2026-10-02
|
data/README.md
CHANGED
|
@@ -154,6 +154,8 @@ rake release:slack[text,channel,emoji] # Send a message to Slack
|
|
|
154
154
|
2. **Release** (`rake release`): Tag the release commit on `main`, push the tag, announce
|
|
155
155
|
the release in Slack, then open the PR that bumps `main` to the next version.
|
|
156
156
|
|
|
157
|
+
Set `DISCHARGER_RELEASE_CONFIRM=1` to run `release:prepare` and `release` without a TTY.
|
|
158
|
+
|
|
157
159
|
`rake release` tags the newest commit that changed the current version's dated changelog
|
|
158
160
|
section, so work merged after finalizing (or re-finalizing for a hotfix) is left out.
|
|
159
161
|
Production ships the tagged commit, which can be older than what staging last ran.
|
data/lib/discharger/task.rb
CHANGED
|
@@ -220,8 +220,28 @@ module Discharger
|
|
|
220
220
|
end
|
|
221
221
|
|
|
222
222
|
def confirm_or_exit!
|
|
223
|
+
if ENV["DISCHARGER_RELEASE_CONFIRM"] == "1"
|
|
224
|
+
sysecho "Confirmation taken from DISCHARGER_RELEASE_CONFIRM"
|
|
225
|
+
return
|
|
226
|
+
end
|
|
227
|
+
|
|
223
228
|
sysecho "Are you ready to continue? (Press Enter to continue, Type 'x' and Enter to exit)".bg(:yellow).black
|
|
224
|
-
|
|
229
|
+
input = $stdin.gets
|
|
230
|
+
if input.nil?
|
|
231
|
+
yield if block_given?
|
|
232
|
+
abort "Run this task interactively or set DISCHARGER_RELEASE_CONFIRM=1."
|
|
233
|
+
end
|
|
234
|
+
return unless input.chomp.match?(/^x/i)
|
|
235
|
+
|
|
236
|
+
yield if block_given?
|
|
237
|
+
exit
|
|
238
|
+
end
|
|
239
|
+
|
|
240
|
+
def discard_branch!(branch)
|
|
241
|
+
syscall(
|
|
242
|
+
["git checkout #{working_branch}"],
|
|
243
|
+
["git branch -D #{branch}"]
|
|
244
|
+
)
|
|
225
245
|
end
|
|
226
246
|
|
|
227
247
|
def post_to_slack(text, emoji = nil, thread_ts = nil)
|
|
@@ -441,7 +461,7 @@ module Discharger
|
|
|
441
461
|
If you need to make changes, edit the CHANGELOG and save the file.
|
|
442
462
|
Then return here to continue with this commit.
|
|
443
463
|
MSG
|
|
444
|
-
confirm_or_exit!
|
|
464
|
+
confirm_or_exit! { discard_branch!(finish_branch) }
|
|
445
465
|
|
|
446
466
|
tasker["reissue:finalize"].invoke
|
|
447
467
|
|
data/lib/discharger/version.rb
CHANGED