asdf/.github/workflows/lint.yml

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

53 lines
1.2 KiB
YAML
Raw Normal View History

name: Lint
on:
push:
branches:
- master
pull_request:
2023-05-31 01:19:34 -07:00
env:
PYTHON_MIN_VERSION: "3.7.13"
2023-05-31 01:19:34 -07:00
jobs:
asdf-bash:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: asdf-vm/actions/install@v3
- uses: actions/setup-python@v5
with:
2023-05-31 01:19:34 -07:00
python-version: ${{ env.PYTHON_MIN_VERSION }}
- run: scripts/install_dependencies.bash
- run: scripts/lint.bash --check
asdf-golang:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v4
with:
go-version: '1.21.5'
- name: Install dependencies
run: go get .
- name: Check format
run: '[ -z "$(gofmt -l ./...)" ]'
- name: Vet
run: go vet
- name: Install staticcheck for linting
run: go install honnef.co/go/tools/cmd/staticcheck@latest
- name: Lint
run: staticcheck -tests -show-ignored ./...
- name: Build
run: go build -v ./...
2023-05-31 01:19:34 -07:00
actions:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check workflow files
2023-05-31 01:19:34 -07:00
uses: docker://rhysd/actionlint:1.6.24
with:
args: -color