Skip to content

Commit 16f87bf

Browse files
committed
cd: fix completion scripts corruption
The goreleaser tool runs builds and build hooks in parallel, which can sometimes cause multiple completion generation processes to write to the same file at the same time. To fix this, move the completion script generation outside of the "builds" section.
1 parent 4ba0521 commit 16f87bf

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.goreleaser.yml

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
before:
22
hooks:
33
- go mod download
4+
- mage genCompletion # generate completion scripts. In global hook to avoid parallel writing.
45

56
env:
67
- GO111MODULE=on
@@ -25,10 +26,6 @@ builds:
2526
goarch:
2627
- amd64
2728

28-
hooks:
29-
pre:
30-
- mage genCompletion # generate completion scripts
31-
3229
archives:
3330
-
3431
id: "cartridge"

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
66
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
77

8+
## [Unreleased]
9+
10+
### Fixed
11+
12+
- Completion scripts corruption during package release.
13+
814
## [2.12.11] - 2024-04-02
915

1016
### Changed

0 commit comments

Comments
 (0)