install reviewdog to $HOME/bin
@@ -19,26 +19,25 @@ jobs:
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: Add $GOPATH/bin
- run: |
- echo ::add-path::$(go env GOPATH)
- echo $PATH
-
- name: Setup reviewdog
run: |
- echo $PATH
- sudo curl -sfL https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh| sh -s -- -b /usr/local/bin
+ 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: |
- PATH=$(go env GOPATH)/bin:$PATH
+ echo $PATH
reviewdog -reporter=github-pr-check -runners=golint,govet
