github-action: add prepare-source test to linting
This is inspired by PR #307, but uses github actions rather than Travis. Signed-off-by: Tom Gundersen <teg@jklm.no>
This commit is contained in:
parent
efb2975e36
commit
c50aa9e135
1 changed files with 12 additions and 0 deletions
12
.github/workflows/tests.yml
vendored
12
.github/workflows/tests.yml
vendored
|
|
@ -25,6 +25,18 @@ jobs:
|
|||
- name: Check out code into the Go module directory
|
||||
uses: actions/checkout@v1
|
||||
|
||||
- name: Check that source has been prepared
|
||||
run: |
|
||||
./tools/prepare-source.sh
|
||||
if ! git diff --quiet --exit-code ; then
|
||||
echo
|
||||
echo "Please include these changes in your branch: "
|
||||
git diff
|
||||
exit "1"
|
||||
else
|
||||
exit "0"
|
||||
fi
|
||||
|
||||
- name: Install golangci-lint
|
||||
run: curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s -- -b $(go env GOPATH)/bin v1.23.7
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue