This repository has been archived by the owner on Apr 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 566
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* ci: update goreleaser * bump version
- Loading branch information
Showing
3 changed files
with
66 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,38 @@ | ||
name: goreleaser | ||
|
||
# This workflow helps with creating releases. | ||
# This job will only be triggered when a tag (vX.X.x) is pushed | ||
name: Release | ||
on: | ||
push: | ||
# Sequence of patterns matched against refs/tags | ||
tags: | ||
- "v*.*.*" | ||
- "v[0-9]+.[0-9]+.[0-9]+" # Push events to matching v*, i.e. v1.0, v20.15.10 | ||
|
||
jobs: | ||
goreleaser: | ||
release: | ||
runs-on: ubuntu-latest | ||
environment: release | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
- name: Set up Go | ||
uses: actions/setup-go@v2 | ||
fetch-depth: 0 | ||
- uses: actions/[email protected] | ||
with: | ||
go-version: 1.17 | ||
- name: release dry run | ||
run: make release-dry-run | ||
- name: setup release environment | ||
- name: Set Env | ||
run: echo "TM_VERSION=$(go list -m github.com/tendermint/tendermint | sed 's:.* ::')" >> $GITHUB_ENV | ||
- name: Build | ||
uses: goreleaser/[email protected] | ||
if: ${{ github.event_name == 'pull_request' }} | ||
with: | ||
version: latest | ||
args: build --rm-dist --skip-validate # skip validate skips initial sanity checks in order to be able to fully run | ||
env: | ||
TM_VERSION: ${{ env.TM_VERSION }} | ||
- name: Release | ||
uses: goreleaser/goreleaser-action@v2 | ||
if: startsWith(github.ref, 'refs/tags/') | ||
with: | ||
version: latest | ||
args: release --rm-dist --release-notes ./RELEASE_NOTES.md | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: |- | ||
echo 'GITHUB_TOKEN=${{secrets.GITHUB_TOKEN}}' > .release-env | ||
- name: release publish | ||
run: make release | ||
TM_VERSION: ${{ env.TM_VERSION }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,109 +1,56 @@ | ||
--- | ||
project_name: ethermint | ||
|
||
env: | ||
- GO111MODULE=on | ||
|
||
before: | ||
hooks: | ||
- go mod download | ||
- go mod tidy | ||
|
||
builds: | ||
- id: "ethermintd-darwin" | ||
main: ./cmd/ethermintd | ||
binary: bin/ethermintd | ||
env: | ||
- CGO_ENABLED=1 | ||
- CC=o64-clang | ||
- CXX=o64-clang++ | ||
goos: | ||
- darwin | ||
goarch: | ||
- amd64 | ||
- main: ./cmd/ethermintd | ||
id: "ethermintd" | ||
binary: ethermintd | ||
mod_timestamp: "{{ .CommitTimestamp }}" | ||
flags: | ||
- -tags=cgo | ||
ldflags: | ||
- -s -w -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{.Version}} -X github.com/cosmos/cosmos-sdk/version.Commit={{.Commit}} | ||
- id: "ethermintd-darwin-arm64" | ||
main: ./cmd/ethermintd | ||
binary: bin/ethermintd | ||
- -tags=netgo ledger | ||
- -trimpath | ||
env: | ||
- CGO_ENABLED=1 | ||
- CC=oa64-clang | ||
- CXX=oa64-clang++ | ||
goos: | ||
- darwin | ||
goarch: | ||
- arm64 | ||
flags: | ||
- -tags=cgo | ||
- CGO_ENABLED=0 | ||
ldflags: | ||
- -s -w -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{.Version}} -X github.com/cosmos/cosmos-sdk/version.Commit={{.Commit}} | ||
- id: "ethermintd-linux" | ||
main: ./cmd/ethermintd | ||
binary: bin/ethermintd | ||
env: | ||
- CGO_ENABLED=1 | ||
- CC=gcc | ||
- CXX=g++ | ||
- -s -w -X main.commit={{.Commit}} -X main.date={{ .CommitDate }} -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{ .Version }} -X github.com/cosmos/cosmos-sdk/version.Commit={{ .Commit }} -X github.com/cosmos/cosmos-sdk/version.BuildTags=netgo,ledger -X github.com/tendermint/tendermint/version.TMCoreSemVer={{ .Env.TM_VERSION }} | ||
goos: | ||
- darwin | ||
- linux | ||
goarch: | ||
- amd64 | ||
flags: | ||
- -tags=cgo | ||
ldflags: | ||
- -s -w -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{.Version}} -X github.com/cosmos/cosmos-sdk/version.Commit={{.Commit}} | ||
- id: "ethermintd-linux-arm64" | ||
main: ./cmd/ethermintd | ||
binary: bin/ethermintd | ||
env: | ||
- CGO_ENABLED=1 | ||
- CC=aarch64-linux-gnu-gcc | ||
- CXX=aarch64-linux-gnu-g++ | ||
goos: | ||
- linux | ||
goarch: | ||
- arm | ||
- arm64 | ||
flags: | ||
- -tags=cgo | ||
ldflags: | ||
- -s -w -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{.Version}} -X github.com/cosmos/cosmos-sdk/version.Commit={{.Commit}} | ||
- id: "ethermintd-windows" | ||
main: ./cmd/ethermintd | ||
binary: bin/ethermintd | ||
env: | ||
- CGO_ENABLED=1 | ||
- CC=x86_64-w64-mingw32-gcc | ||
- CXX=x86_64-w64-mingw32-g++ | ||
goos: | ||
- windows | ||
goarch: | ||
- amd64 | ||
flags: | ||
- -tags=cgo | ||
- -buildmode=exe | ||
ldflags: | ||
- -s -w -X github.com/cosmos/cosmos-sdk/version.Name=ethermint -X github.com/cosmos/cosmos-sdk/version.AppName=ethermintd -X github.com/cosmos/cosmos-sdk/version.Version={{.Version}} -X github.com/cosmos/cosmos-sdk/version.Commit={{.Commit}} | ||
|
||
archives: | ||
- name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}' | ||
replacements: | ||
darwin: Darwin | ||
linux: Linux | ||
windows: Windows | ||
amd64: x86_64 | ||
format_overrides: | ||
- goos: windows | ||
format: zip | ||
builds: | ||
- ethermintd-darwin | ||
- ethermintd-darwin-arm64 | ||
- ethermintd-windows | ||
- ethermintd-linux | ||
- ethermintd-linux-arm64 | ||
- format: tar.gz | ||
wrap_in_directory: true | ||
format_overrides: | ||
- goos: windows | ||
format: zip | ||
name_template: "{{ .Binary }}-v{{ .Version }}-{{ .Os }}-{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}" | ||
files: | ||
- LICENSE | ||
- README.md | ||
|
||
release: | ||
github: | ||
owner: tharsis | ||
name: ethermint | ||
name_template: "v{{.Version}}" | ||
|
||
checksum: | ||
name_template: 'checksums.txt' | ||
changelog: | ||
sort: asc | ||
filters: | ||
exclude: | ||
- '^docs:' | ||
- '^test:' | ||
name_template: SHA256SUMS-v{{.Version}}.txt | ||
algorithm: sha256 | ||
|
||
snapshot: | ||
name_template: "{{ .Tag }}-next" | ||
name_template: SNAPSHOT-{{ .Commit }} | ||
|
||
changelog: | ||
skip: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters