Merge pull request #140 from spacemeshos/dependabot/go_modules/github… #283
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: CI | |
env: | |
go-version: "1.23" | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the main branch | |
on: | |
pull_request: | |
push: | |
branches: [develop] | |
jobs: | |
quicktests: | |
runs-on: ubuntu-latest | |
timeout-minutes: 2 | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ env.go-version }} | |
- name: fmt, tidy | |
run: | | |
make install | |
make test-fmt | |
make test-tidy | |
lint: | |
runs-on: ubuntu-latest | |
timeout-minutes: 2 | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ env.go-version }} | |
- name: lint | |
run: | | |
make install | |
make lint | |
build: | |
runs-on: ubuntu-latest | |
timeout-minutes: 2 | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: install udev | |
run: sudo apt-get install -y libudev-dev | |
- name: set up go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ env.go-version }} | |
- name: build | |
run: make build | |
test: | |
runs-on: ubuntu-latest | |
timeout-minutes: 2 | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ env.go-version }} | |
- name: go test | |
run: make test |