-
Notifications
You must be signed in to change notification settings - Fork 1
35 lines (35 loc) · 966 Bytes
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: CI
on:
push:
branches:
- master
pull_request: ~
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get Go version from .mise.toml
uses: SebRollen/[email protected]
id: get-golang-version
with:
file: .mise.toml
field: tools.golang
- uses: actions/setup-go@v5
with:
go-version: '${{ steps.get-golang-version.outputs.value }}'
- name: Get golangci-lint version from .mise.toml
uses: SebRollen/[email protected]
id: get-golangci-lint-version
with:
file: .mise.toml
field: tools.golangci-lint
- name: golangci-lint
uses: golangci/golangci-lint-action@v5
with:
version: 'v${{ steps.get-golangci-lint-version.outputs.value }}'
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pre-commit/[email protected]