chore: fixed goreleaser options (#1059)

This commit is contained in:
James Read 2026-06-28 23:56:36 +00:00 committed by GitHub
commit 28434e8ed0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 4 deletions

View File

@ -6,7 +6,8 @@ before:
- make windows-resources VERSION={{ .Version }} - make windows-resources VERSION={{ .Version }}
builds: builds:
- env: - skip: '{{ isEnvSet "GORELEASER_SKIP_BUILD" }}'
env:
- CGO_ENABLED=0 - CGO_ENABLED=0
binary: OliveTin binary: OliveTin
main: main.go main: main.go

View File

@ -2,6 +2,8 @@
set -euo pipefail set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)"
GORELEASER_CONFIG="${REPO_ROOT}/.goreleaser.yml"
TIMEOUT="${GORELEASER_TIMEOUT:-60m}" TIMEOUT="${GORELEASER_TIMEOUT:-60m}"
if [[ -z "${VERSION:-}" ]]; then if [[ -z "${VERSION:-}" ]]; then
@ -9,9 +11,13 @@ if [[ -z "${VERSION:-}" ]]; then
exit 1 exit 1
fi fi
goreleaser release --clean --timeout "${TIMEOUT}" --skip=checksum,publish "$@" build_config="$(mktemp)"
trap 'rm -f "${build_config}"' EXIT
awk '/^checksum:/{print; print " disable: true"; next}1' "${GORELEASER_CONFIG}" > "${build_config}"
goreleaser release -f "${build_config}" --clean --timeout "${TIMEOUT}" --skip=publish "$@"
"${SCRIPT_DIR}/build-msi.sh" "${SCRIPT_DIR}/build-msi.sh"
goreleaser release --timeout "${TIMEOUT}" \ GORELEASER_SKIP_BUILD=1 goreleaser release --timeout "${TIMEOUT}" \
--skip=validate,before,build,archive,nfpm,docker,sign,sbom,after,announce "$@" --skip=validate,before,archive,nfpm,docker,sign,sbom,announce "$@"