41 lines
947 B
YAML
41 lines
947 B
YAML
name: release
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- "*"
|
|
|
|
jobs:
|
|
release:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: setup go
|
|
uses: https://github.com/actions/setup-go@v4
|
|
with:
|
|
go-version: '>=1.20.1'
|
|
|
|
- name: Install go-gitea/changelog
|
|
run: |
|
|
go get github.com/go-gitea/changelog
|
|
|
|
- name: Generate changelog
|
|
id: changelog
|
|
run: |
|
|
changelog --config changelog.yml > CHANGELOG.md
|
|
echo "changelog<<EOF" >> $GITHUB_OUTPUT
|
|
cat CHANGELOG.md >> $GITHUB_OUTPUT
|
|
echo "EOF" >> $GITHUB_OUTPUT
|
|
|
|
- name: Create Gitea Release
|
|
uses: akkuman/gitea-release-action@v1
|
|
with:
|
|
token: ${{ secrets.GITEA_TOKEN }}
|
|
tag_name: ${{ gitea.ref_name }}
|
|
name: ${{ gitea.ref_name }}
|
|
body: ${{ steps.changelog.outputs.changelog }}
|
|
|