Website update for main #834
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
name: Go | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
name: Build Go scripts | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'scripts/go.mod' | |
cache-dependency-path: 'scripts/go.sum' | |
- name: Build | |
working-directory: ./scripts | |
run: make | |
tidy: | |
name: Tidiness | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'scripts/go.mod' | |
cache-dependency-path: 'scripts/go.sum' | |
- name: Check tidiness | |
working-directory: ./scripts | |
run: ./ci/check-tidy.sh | |
golangci: | |
name: Run code linters for Go scripts | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'scripts/go.mod' | |
cache-dependency-path: 'scripts/go.sum' | |
- name: Build | |
working-directory: ./scripts | |
run: make golangci | |
test-unit: | |
name: Unit tests | |
runs-on: [ubuntu-latest] | |
steps: | |
- name: Check-out code | |
uses: actions/checkout@v4 | |
- name: Set up Go using version from go.mod | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'scripts/go.mod' | |
cache-dependency-path: 'scripts/go.sum' | |
- name: Run unit tests | |
working-directory: ./scripts | |
run: make test-unit |