Trigger Release #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Trigger Release | |
on: | |
workflow_dispatch: | |
jobs: | |
archive: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: main | |
token: ${{ secrets.BOT_TOKEN }} | |
persist-credentials: false | |
- name: Setup Python environment | |
uses: ./.github/actions/setup-python | |
- run: echo "TAG_NAME=v$(pdm show --version)" >> $GITHUB_ENV | |
- name: Archive Changelog | |
uses: docker://ghcr.io/nonebot/auto-changelog:master | |
with: | |
archive_regex: '(?<=## )最近更新(?=\n)' | |
archive_title: ${{ env.TAG_NAME }} | |
commit_and_push: false | |
- name: Push Tag | |
run: | | |
git config user.name BotLunacub | |
git config user.email [email protected] | |
git remote set-url origin https://${{ secrets.GH_PAT }}@github.com/GuGuMur/nonebot-plugin-skland-arksign.git | |
git add . | |
git commit -m ":bookmark: Release $(pdm show --version)" | |
git tag ${{ env.TAG_NAME }} | |
git push -f && git push -f --tags |