nonebot2/.github/workflows/release-github.yml
2021-12-02 03:17:10 +08:00

29 lines
646 B
YAML

name: Release Drafter
on:
push:
branches:
- master
tags:
- v*
jobs:
update-release-draft:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: release-drafter/release-drafter@v5
if: github.ref == 'refs/heads/master'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: release-drafter/release-drafter@v5
if: startsWith(github.ref, 'refs/tags/')
with:
name: Release v${GITHUB_REF#refs/tags/} 🌈
tag: ${GITHUB_REF#refs/tags/}
publish: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}