adept/.woodpecker.yml
Gregory Ballantine 9b59d7485e
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Added a version subcommand
2022-09-16 23:21:47 -04:00

34 lines
883 B
YAML

pipeline:
build_test:
image: golang:1.16
commands:
- go build
test:
image: golang:1.16
commands:
- apt update
- apt install -f lsof
- go test -v ./...
build_release:
image: golang:1.16
commands:
- go mod vendor
- GOOS=linux GOARCH=amd64 go build -ldflags "-X git.metaunix.net/BitGoblin/adept/cmd.version=${CI_COMMIT_TAG}" -o "dist/adept-linux-amd64-${CI_COMMIT_TAG}"
- GOOS=windows GOARCH=amd64 go build -ldflags "-X git.metaunix.net/BitGoblin/adept/cmd.version=${CI_COMMIT_TAG}" -o "dist/adept-windows-amd64-${CI_COMMIT_TAG}.exe"
when:
event: tag
gitea_release:
image: plugins/gitea-release
settings:
api_key:
from_secret: gitea_api_key
base_url: https://git.metaunix.net
title: "${CI_COMMIT_TAG}"
files:
- dist/adept-*
when:
event: tag