Work on GitHub actions (#133)

This does:
* Use actions/checkout@v3 (fixes node.js v12 deprecation warning)
* Pin Go version to 1.18.8 to make caching work better
* Remove checkout of submodules (we don't have any anymore)
This commit is contained in:
Pieter Noordhuis 2022-12-12 16:51:27 +01:00 committed by GitHub
parent d713521d63
commit 58e6ba3483
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 13 deletions

View File

@ -18,13 +18,9 @@ jobs:
- ubuntu-latest - ubuntu-latest
- windows-latest - windows-latest
steps: steps:
- name: Checkout repository and submodules - name: Checkout repository and submodules
uses: actions/checkout@v2 uses: actions/checkout@v3
with:
token: ${{ secrets.DECO_GITHUB_TOKEN }}
submodules: recursive
- name: Unshallow - name: Unshallow
run: git fetch --prune --unshallow run: git fetch --prune --unshallow
@ -32,7 +28,7 @@ jobs:
- name: Setup Go - name: Setup Go
uses: actions/setup-go@v3 uses: actions/setup-go@v3
with: with:
go-version: 1.18.x go-version: 1.18.8
cache: true cache: true
- name: Set go env - name: Set go env
@ -53,12 +49,12 @@ jobs:
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v2 uses: actions/checkout@v3
- name: Setup Go - name: Setup Go
uses: actions/setup-go@v3 uses: actions/setup-go@v3
with: with:
go-version: 1.18.x go-version: 1.18.8
# No need to download cached dependencies when running gofmt. # No need to download cached dependencies when running gofmt.
cache: false cache: false

View File

@ -10,17 +10,17 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout repository and submodules - name: Checkout repository and submodules
uses: actions/checkout@v2 uses: actions/checkout@v3
with:
token: ${{ secrets.DECO_GITHUB_TOKEN }}
submodules: recursive
- name: Unshallow - name: Unshallow
run: git fetch --prune --unshallow run: git fetch --prune --unshallow
- name: Setup Go - name: Setup Go
uses: actions/setup-go@v3 uses: actions/setup-go@v3
with: with:
go-version: 1.18 go-version: 1.18.8
cache: true cache: true
- name: Run GoReleaser - name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3.1.0 uses: goreleaser/goreleaser-action@v3.1.0
with: with: