Skip to content

Commit 26ea41a

Browse files
committed
Add a CI workflow to lint code
1 parent 6ec2983 commit 26ea41a

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

Diff for: .github/workflows/lint-code.yml

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Lint code
2+
3+
on:
4+
push:
5+
paths:
6+
- ".github/workflows/lint-code.yml"
7+
- "Taskfile.yml"
8+
- "go.mod"
9+
- "go.sum"
10+
- "**/*.go"
11+
pull_request:
12+
paths:
13+
- ".github/workflows/lint-code.yml"
14+
- "Taskfile.yml"
15+
- "go.mod"
16+
- "go.sum"
17+
- "**/*.go"
18+
19+
jobs:
20+
lint:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- name: Checkout local repository
24+
uses: actions/checkout@v2
25+
26+
- name: Install Taskfile
27+
uses: arduino/actions/setup-taskfile@master
28+
with:
29+
repo-token: ${{ secrets.GITHUB_TOKEN }}
30+
version: 3.x
31+
32+
- name: Install golint
33+
run: |
34+
go get golang.org/x/lint/golint
35+
36+
- name: Lint Go code
37+
run: task go:lint

0 commit comments

Comments
 (0)