-
Notifications
You must be signed in to change notification settings - Fork 13
43 lines (37 loc) · 1006 Bytes
/
lint.yaml
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
36
37
38
39
40
41
42
43
name: Lint
on:
push:
paths:
- "**/*.go"
workflow_dispatch:
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
env:
GOFLAGS: -mod=readonly
strategy:
max-parallel: 6
fail-fast: false
matrix:
directory: ["client", "server", "e2e"]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: ${{ matrix.directory }}/go.mod
- name: Install Task
uses: arduino/setup-task@v2
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install prettier
run: task -p deps:install:prettier
- name: Lint
run: task -p lint
- name: Install linter
run: curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.57.1
- name: Lint
working-directory: ${{ matrix.directory }}
run: make lint