Skip to content

Commit 85e31a2

Browse files
authored
Merge pull request #2 from golangci/release-04-26
Update readme and action
2 parents 7a50c22 + 9c54359 commit 85e31a2

File tree

3 files changed

+22
-3
lines changed

3 files changed

+22
-3
lines changed

.github/workflows/golangci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ jobs:
1010
- name: golangci-lint
1111
uses: ./
1212
with:
13-
github_token: ${{ secrets.github_token }}
1413
directory: sample
1514
format: colored-line-number
1615
flags: --issues-exit-code 0

README.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,25 @@
11
# golangci-lint-action
22

3-
Work in progress
3+
![docker image](https://github.com/golangci/golangci-lint-action/workflows/docker%20image/badge.svg)
4+
5+
Action that runs [golangci-lint](https://github.com/golangci/golangci-lint) and reports issues from linters.
6+
7+
You can put `.github/workflows/lint.yml` with following contents:
8+
```yaml
9+
name: golangci
10+
on: [push]
11+
jobs:
12+
golangci:
13+
name: lint
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Check out code into the Go module directory
17+
uses: actions/checkout@v1
18+
- name: golangci-lint
19+
uses: golangci/[email protected]
20+
with:
21+
github_token: ${{ secrets.github_token }}
22+
23+
```
424

525
Based on [reviewdog action](https://github.com/reviewdog/action-golangci-lint).

action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: 'golangci'
55
inputs:
66
github_token:
77
description: 'GITHUB_TOKEN'
8-
required: true
8+
required: false
99
flags:
1010
description: 'GolangCI command line flags'
1111
required: false

0 commit comments

Comments
 (0)