parent
ac63841684
commit
c6344456e8
|
@ -1,6 +1,6 @@
|
|||
# template.toml
|
||||
# Write any template args here to prompt the user for, giving any defaults/options as applicable
|
||||
|
||||
name = "MyProject"
|
||||
|
||||
lang = ["Go", "Rust", "Python"]
|
||||
gitea_url = "https://git.jojodev.com"
|
||||
gitea_user = ""
|
||||
gitea_repo = ""
|
||||
name = "${TMPL_PROMPT_GITEA_REPO}"
|
||||
module = "${TMPL_PROMPT_GITEA_URL}/${TMPL_PROMPT_GITEA_USER}/${TMPL_PROMPT_GITEA_REPO}"
|
||||
version_package = "${TMPL_PROMPT_MODULE}/cmd"
|
|
@ -0,0 +1,25 @@
|
|||
builds:
|
||||
- env:
|
||||
- CGO_ENABLED=0
|
||||
goos:
|
||||
- linux
|
||||
- windows
|
||||
- darwin
|
||||
ldflags:
|
||||
- "-s -w -X {{version_package}}.Version={{`{{.Version}}`}}"
|
||||
archives:
|
||||
- replacements:
|
||||
386: i386
|
||||
amd64: x86_64
|
||||
format_overrides:
|
||||
- goos: windows
|
||||
format: zip
|
||||
checksum:
|
||||
name_template: 'checksums.txt'
|
||||
release:
|
||||
gitea:
|
||||
owner: jolheiser
|
||||
name: {{gitea_repo}}
|
||||
gitea_urls:
|
||||
api: {{gitea_url}}/api/v1/
|
||||
download: {{gitea_url}}
|
|
@ -1 +0,0 @@
|
|||
Delete this file and put something else here!
|
|
@ -0,0 +1,39 @@
|
|||
clone:
|
||||
git:
|
||||
image: woodpeckerci/plugin-git
|
||||
settings:
|
||||
tags: true
|
||||
|
||||
pipeline:
|
||||
compliance:
|
||||
image: golang:1.18
|
||||
commands:
|
||||
- go test -race ./...
|
||||
- go vet ./...
|
||||
- go run github.com/rs/zerolog/cmd/lint@latest {{module}}
|
||||
when:
|
||||
event: pull_request
|
||||
|
||||
build:
|
||||
image: goreleaser/goreleaser
|
||||
commands:
|
||||
- goreleaser build --snapshot
|
||||
when:
|
||||
event: pull_request
|
||||
|
||||
release:
|
||||
image: goreleaser/goreleaser
|
||||
commands:
|
||||
- goreleaser release
|
||||
secrets: [ gitea_token ]
|
||||
when:
|
||||
event: tag
|
||||
|
||||
prune:
|
||||
image: jolheiser/drone-gitea-prune
|
||||
settings:
|
||||
base: {{gitea_url}}
|
||||
token:
|
||||
from_secret: gitea_token
|
||||
when:
|
||||
event: tag
|
Loading…
Reference in New Issue