Skip to content

Commit

Permalink
Merge pull request #2363 from carapace-sh/goreleaser-fix-termux
Browse files Browse the repository at this point in the history
goreleaser: fix termux
  • Loading branch information
rsteube authored May 5, 2024
2 parents 8f1c133 + 46493c8 commit 998a9aa
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 7 deletions.
11 changes: 5 additions & 6 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ jobs:

build:
runs-on: ubuntu-latest
container: ghcr.io/carapace-sh/go:1.22
steps:
- name: shallow clone
uses: actions/checkout@v4
Expand All @@ -19,11 +20,9 @@ jobs:
with:
fetch-depth: 0

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.21'

- name: fix git safe.directory
run: git config --global --add safe.directory '*'

- name: Generate
run: go generate ./cmd/...

Expand Down Expand Up @@ -52,7 +51,7 @@ jobs:
uses: goreleaser/goreleaser-action@v5
if: startsWith(github.ref, 'refs/tags/')
with:
version: latest
version: nightly # switch back to stable when #4812 is merged
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
15 changes: 14 additions & 1 deletion .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ before:
- go mod download
- go generate ./cmd/...
builds:
- env:
- id: default
env:
- CGO_ENABLED=0
goos:
- linux
Expand All @@ -13,6 +14,18 @@ builds:
binary: carapace
tags:
- release
- id: android
env:
- CGO_ENABLED=0
goos:
- android
goarch:
- arm64
main: ./cmd/carapace
binary: carapace
tags:
- release
gobinary: go-termux
archives:
- name_template: '{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}'
format_overrides:
Expand Down

0 comments on commit 998a9aa

Please sign in to comment.