Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add on: push GitHub Actions workflow and run reviewdog with -reporter…
…=github-check
- Loading branch information
1 parent
2d7e23e
commit dde68ca
Showing
2 changed files
with
36 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: reviewdog on GitHub Action | ||
name: reviewdog on Pull Request | ||
on: [pull_request] | ||
jobs: | ||
reviewdog: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: reviewdog on Push | ||
on: [push] | ||
jobs: | ||
reviewdog: | ||
name: reviewdog | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Go | ||
uses: actions/setup-go@v1 | ||
with: | ||
go-version: 1.13 | ||
id: go | ||
|
||
- name: Add $GOPATH/bin | ||
run: | | ||
echo ::add-path::$(go env GOPATH)/bin | ||
- name: Check out code into the Go module directory | ||
uses: actions/checkout@v1 | ||
|
||
- name: Install linters | ||
run: '( cd linters && go get golang.org/x/lint/golint )' | ||
|
||
- name: Setup reviewdog | ||
run: | | ||
# mkdir -p $HOME/bin && curl -sfL https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh| sh -s -- -b $HOME/bin | ||
# echo ::add-path::$HOME/bin | ||
go install ./cmd/reviewdog | ||
- name: Run reviewdog | ||
env: | ||
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
reviewdog -reporter=github-check -runners=golint,govet | ||