mirror of
https://codeberg.org/Codeberg/pages-server.git
synced 2024-11-23 06:18:59 +00:00
f2ba7eac64
Co-authored-by: 6543 <6543@obermui.de> Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/84
25 lines
505 B
YAML
25 lines
505 B
YAML
pipeline:
|
|
# use vendor to cache dependencies
|
|
vendor:
|
|
image: golang:1.18
|
|
commands:
|
|
- go mod vendor
|
|
|
|
lint:
|
|
image: golangci/golangci-lint:v1.45.2
|
|
commands:
|
|
- go version
|
|
- go install mvdan.cc/gofumpt@latest
|
|
- "[ $(gofumpt -extra -l . | wc -l) != 0 ] && { echo 'code not formated'; exit 1; }"
|
|
- golangci-lint run --timeout 5m
|
|
|
|
test:
|
|
image: golang:1.18
|
|
commands:
|
|
- go test ./...
|
|
|
|
build:
|
|
image: golang:1.18
|
|
commands:
|
|
- go build
|