mirror of
https://github.com/niusmallnan/steve.git
synced 2025-07-11 21:38:04 +00:00
Add go generate to CI
This commit is contained in:
parent
72ab913c4c
commit
1f2f28e0e2
@ -3,7 +3,7 @@ kind: pipeline
|
|||||||
name: fossa
|
name: fossa
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: fossa
|
- name: fossa
|
||||||
image: rancher/drone-fossa:latest
|
image: rancher/drone-fossa:latest
|
||||||
settings:
|
settings:
|
||||||
api_key:
|
api_key:
|
||||||
@ -38,6 +38,7 @@ steps:
|
|||||||
- zypper in -y go=1.19 git tar gzip make
|
- zypper in -y go=1.19 git tar gzip make
|
||||||
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.49.0
|
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.49.0
|
||||||
- mv ./bin/golangci-lint /usr/local/bin/golangci-lint
|
- mv ./bin/golangci-lint /usr/local/bin/golangci-lint
|
||||||
|
- GOBIN=/usr/local/bin go install github.com/golang/mock/mockgen@v1.6.0
|
||||||
- make validate
|
- make validate
|
||||||
when:
|
when:
|
||||||
event:
|
event:
|
||||||
|
@ -1,12 +1,13 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
go generate ./..
|
||||||
golangci-lint run
|
golangci-lint run
|
||||||
go mod tidy
|
go mod tidy
|
||||||
go mod verify
|
go mod verify
|
||||||
unclean=$(git status --porcelain --untracked-files=no)
|
unclean=$(git status --porcelain --untracked-files=no)
|
||||||
if [ -n "$unclean" ]; then
|
if [ -n "$unclean" ]; then
|
||||||
echo "Encountered dirty repo!";
|
echo "Encountered dirty repo!"
|
||||||
echo "$unclean";
|
echo "$unclean"
|
||||||
exit 1;
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user