go-plugin/.woodpecker.yaml
Lauris BH ca1f8e48fe Update pipeline with Go code review (#25)
Reviewed-on: https://codeberg.org/woodpecker-plugins/go-plugin/pulls/25
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-committed-by: Lauris BH <lauris@nix.lv>
2024-03-30 15:52:30 +00:00

35 lines
688 B
YAML

when:
- event: [pull_request, tag, cron]
- event: push
branch:
- ${CI_REPO_DEFAULT_BRANCH}
- 'renovate/*'
variables:
- &golang "golang:1.22"
- &golangci-lint "golangci/golangci-lint:v1.57-alpine"
- &reviewdog-golangci-lint "woodpeckerci/plugin-reviewdog-golangci-lint:1.57"
steps:
vendor:
image: *golang
commands: go mod vendor
review-go:
image: *reviewdog-golangci-lint
settings:
token:
from_secret: reviewdog_token
when:
event: pull_request
lint:
image: *golangci-lint
commands: golangci-lint run
when:
event: [push, tag, cron]
test:
image: *golang
commands: go test --cover ./...