Skip to content

Commit

Permalink
Support only-new-issues (#19)
Browse files Browse the repository at this point in the history
Fixes #16
  • Loading branch information
jirfag committed May 22, 2020
1 parent 64c208b commit 10cbc92
Show file tree
Hide file tree
Showing 9 changed files with 67,982 additions and 13,241 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@ jobs:
npm install
npm run prepare-deps
npm run all
git diff --exit-code
test: # make sure the action works on a clean machine without building
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: ./
with:
version: v1.26
args: --issues-exit-code=0 ./...
working-directory: sample
args: --issues-exit-code=0 ./sample/...
only-new-issues: true
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ jobs:

# Optional: golangci-lint command line arguments.
# args: --issues-exit-code=0

# Optional: show only new issues if it's a pull request. The default value is `false`.
# only-new-issues: true
```

We recommend running this action in a job separate from other jobs (`go test`, etc)
Expand Down
8 changes: 8 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ inputs:
working-directory:
description: 'golangci-lint working directory, default is project root'
required: false
github-token:
description: 'the token is used for fetching patch of a pull request to show only new issues'
default: ${{ github.token }}
required: true
only-new-issues:
description: 'if set to true and the action runs on a pull request - the action outputs only newly found issues'
default: false
required: true

runs:
using: 'node12'
Expand Down

0 comments on commit 10cbc92

Please sign in to comment.