From c9178f5a1e533f503a196edc7f57587444e219d4 Mon Sep 17 00:00:00 2001 From: jackyu Date: Thu, 7 Sep 2023 17:28:24 +0800 Subject: [PATCH] update goreleaser: remove replacements --- .github/workflows/release.yaml | 2 +- .goreleaser.yml | 25 +++++++------------------ 2 files changed, 8 insertions(+), 19 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 45c1e7e..0061e68 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -35,7 +35,7 @@ jobs: uses: goreleaser/goreleaser-action@v3 with: version: latest - args: release --rm-dist + args: release --clean env: GITHUB_TOKEN: ${{ secrets.GH_PUBLISH_SECRETS }} - name: Build image diff --git a/.goreleaser.yml b/.goreleaser.yml index ddb01b1..c9d95f6 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -44,12 +44,6 @@ archives: id: "ks" builds: - ks - replacements: - darwin: darwin - linux: linux - windows: windows - amd64: amd64 - arm64: arm64 format_overrides: - goos: windows format: zip @@ -60,17 +54,13 @@ archives: id: "kubectl-ks" builds: - "kubectl-ks" - replacements: - darwin: darwin - linux: linux - amd64: amd64 files: - README.md - LICENSE checksum: name_template: 'checksums.txt' snapshot: - name_template: "{{ .Tag }}-next-{{.ShortCommit}}" + name_template: "{{ .Tag }}-next-{{ .ShortCommit }}" changelog: skip: true sort: asc @@ -79,7 +69,12 @@ changelog: - '^docs:' - '^test:' nfpms: - - file_name_template: "ks-{{.Os}}-{{.Arch}}" + - file_name_template: >- + ks- + {{- .Os }}- + {{- if eq .Arch "amd64" }}64bit + {{- else if eq .Arch "darwin" }}macOS + {{- else }}{{ .Arch }}{{ end -}} id: "ks" homepage: https://github.com/kubesphere-sigs/ks description: ks is a tool which makes it be easy to work with KubeSphere. @@ -94,9 +89,3 @@ nfpms: - vim - kubectl bindir: /usr/local/bin - replacements: - amd64: 64bit - arm64: arm64 - darwin: macOS - linux: linux - windows: windows