chore(ci): allow manual trigger via issue #437

Merged
luke merged 1 commits from test into main 2025-01-01 01:24:34 +01:00

View File

@ -2,14 +2,25 @@ name: Release
on: on:
schedule: schedule:
- cron: "0 9 * * 0" - cron: "0 9 * * 0"
- cron: "0 0 * * *" # Testing issue_comment:
types: [created]
jobs: jobs:
check_manual_trigger:
runs-on: ubuntu-latest
if: contains(gitea.event.issue.number, '436') || contains(gitea.event.issue.number, 436) # check if the comments come from issue #436
steps:
- name: Allow workflow
if: contains(gitea.event.comment.body, '/trigger-release') && contains(gitea.event.comment.user.login, 'luke')
run: exit 0
test: test:
needs: check_manual_trigger
uses: https://git.tainton.uk/public/webexmemebot/src/branch/main/.gitea/workflows/ci.yml uses: https://git.tainton.uk/public/webexmemebot/src/branch/main/.gitea/workflows/ci.yml
create_release: create_release:
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: test
outputs: outputs:
release_name: ${{ steps.tag_version.outputs.new_tag }} release_name: ${{ steps.tag_version.outputs.new_tag }}
success: ${{ steps.set_flag.outputs.success }} success: ${{ steps.set_flag.outputs.success }}