Publish jars as a Gitea release on tag push
Add a gitea-release step to the Drone pipeline that uploads everything in build/libs/*.jar to a Gitea Release named after the pushed tag, authenticating with a gitea_token secret. The step is guarded with when.event tag, and tag was added to the pipeline trigger so the build itself runs for tag events. Document the one-time token / secret setup and the tag workflow in the README.
This commit is contained in:
16
.drone.yml
16
.drone.yml
@@ -6,6 +6,7 @@ trigger:
|
||||
event:
|
||||
- push
|
||||
- pull_request
|
||||
- tag
|
||||
|
||||
steps:
|
||||
- name: gradle-build
|
||||
@@ -15,3 +16,18 @@ steps:
|
||||
commands:
|
||||
- gradle --no-daemon clean build
|
||||
- ls -la build/libs
|
||||
|
||||
- name: gitea-release
|
||||
image: plugins/gitea-release
|
||||
settings:
|
||||
api_key:
|
||||
from_secret: gitea_token
|
||||
base_url: https://git.nevetime.ru
|
||||
files:
|
||||
- build/libs/*.jar
|
||||
title: ${DRONE_TAG}
|
||||
checksum:
|
||||
- sha256
|
||||
when:
|
||||
event:
|
||||
- tag
|
||||
|
||||
Reference in New Issue
Block a user