pages-server/.woodpecker.yml

33 lines
722 B
YAML

branches: main
pipeline:
# use vendor to cache dependencies
vendor:
image: golang:1.18
commands:
- go mod vendor
lint:
image: golangci/golangci-lint:latest
pull: true
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 codeberg.org/codeberg/pages/server/...
build:
image: golang:1.18
commands:
- go build
integration-tests:
image: golang:1.18
detach: true
commands:
- go test -tags integration codeberg.org/codeberg/pages/integration/...