0
0
mirror of https://github.com/thegeeklab/wp-gitea-release.git synced 2024-09-19 15:12:45 +02:00
Woodpecker CI plugin to publish files and artifacts to Gitea releases
Go to file
Adam Williams b32e6172f5 Fix extraction of tag name from commit ref to handle /
Previously, tags with a `/` character were not correctly handled because
`filepath.Base` was used. This would return the last element of path.

This change allows for tags like `test/v1.2.3` to work properly by
trimming the `refs/tags/` prefix from the commit ref.

Issue #24
2017-05-22 10:13:16 -06:00
vendor Added vendoring 2016-08-26 10:36:43 +02:00
.drone.yml Migrated to 0.5 structure and updated documentation 2016-08-26 10:38:22 +02:00
.drone.yml.sig Migrated to 0.5 structure and updated documentation 2016-08-26 10:38:22 +02:00
.gitignore Updated gitignore file to current convention 2016-08-26 10:37:55 +02:00
Dockerfile Migrated to 0.5 structure and updated documentation 2016-08-26 10:38:22 +02:00
Dockerfile.armhf Added dockerfile for arm builds 2016-08-26 10:36:59 +02:00
DOCS.md Implement prerelease option 2017-03-23 17:14:04 -06:00
LICENSE Implemented initial version based on google/go-github 2015-11-23 22:35:33 +01:00
logo.svg Implemented initial version based on google/go-github 2015-11-23 22:35:33 +01:00
main.go Implement prerelease option 2017-03-23 17:14:04 -06:00
MAINTAINERS Updated maintainers file, added names and athieriot 2016-02-21 11:20:00 +01:00
plugin.go Fix extraction of tag name from commit ref to handle / 2017-05-22 10:13:16 -06:00
README.md Migrated to 0.5 structure and updated documentation 2016-08-26 10:38:22 +02:00
release.go Implement prerelease option 2017-03-23 17:14:04 -06:00
utils.go Migrated to 0.5 structure and updated documentation 2016-08-26 10:38:22 +02:00

drone-github-release

Build Status Go Doc Go Report Join the chat at https://gitter.im/drone/drone

Drone plugin to publish files and artifacts to GitHub Release. For the usage information and a listing of the available options please take a look at the docs.

Build

Build the binary with the following commands:

go build
go test

Docker

Build the docker image with the following commands:

CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -tags netgo
docker build --rm=true -t plugins/github-release .

Please note incorrectly building the image for the correct x64 linux and with GCO disabled will result in an error when running the Docker image:

docker: Error response from daemon: Container command
'/bin/drone-github-release' not found or does not exist..

Usage

Execute from the working directory:

docker run --rm \
  -e DRONE_BUILD_EVENT=tag \
  -e DRONE_REPO_OWNER=octocat \
  -e DRONE_REPO_NAME=foo \
  -e DRONE_COMMIT_REF=refs/heads/master \
  -e PLUGIN_API_KEY=${HOME}/.ssh/id_rsa \
  -e PLUGIN_FILES=master \
  -v $(pwd):$(pwd) \
  -w $(pwd) \
  plugins/github-release