-
Notifications
You must be signed in to change notification settings - Fork 607
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Fix 🔨] Use go mod in build ci (#7361)
* Update golang version in Dockerfile to 1.21 * Use go.mod in build CI
- Loading branch information
1 parent
a5610f3
commit 7c81b90
Showing
1 changed file
with
13 additions
and
10 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 |
---|---|---|
|
@@ -22,9 +22,6 @@ on: | |
- "v[0-9]**" | ||
workflow_dispatch: | ||
|
||
env: | ||
GO_VERSION: "1.20.5" | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
@@ -43,9 +40,11 @@ jobs: | |
arch: arm64 | ||
|
||
steps: | ||
- name: Check out repository code | ||
- | ||
name: Check out repository code | ||
uses: actions/checkout@v4 | ||
- name: Get git diff | ||
- | ||
name: Get git diff | ||
uses: technote-space/[email protected] | ||
with: | ||
PATTERNS: | | ||
|
@@ -56,22 +55,26 @@ jobs: | |
go.sum | ||
Makefile | ||
.github/workflows/build.yml | ||
- name: 🐿 Setup Golang | ||
- | ||
name: 🐿 Setup Golang | ||
uses: actions/setup-go@v5 | ||
if: env.GIT_DIFF | ||
with: | ||
go-version: ${{env.GO_VERSION}} | ||
go-version-file: go.mod | ||
env: | ||
GOOS: ${{ matrix.targetos }} | ||
GOARCH: ${{ matrix.arch }} | ||
- name: Download Dependencies | ||
- | ||
name: Download Dependencies | ||
if: env.GIT_DIFF | ||
run: go mod download | ||
- name: Build osmosisd | ||
- | ||
name: Build osmosisd | ||
if: env.GIT_DIFF | ||
run: | | ||
GOWRK=off go build cmd/osmosisd/main.go | ||
- name: Upload osmosisd artifact | ||
- | ||
name: Upload osmosisd artifact | ||
if: env.GIT_DIFF | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
|