mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-09-08 00:03:28 +00:00
fix(release-notes-assistant): do not trigger on open
Forgejo sets a label and will notify this when opening the pull request. Triggering when it opens will make two workflows for the same SHA. Re-opening is a border case that is not needed.
This commit is contained in:
parent
762f4b5408
commit
e9a3306f6e
1 changed files with 10 additions and 3 deletions
|
@ -1,8 +1,6 @@
|
|||
on:
|
||||
pull_request_target:
|
||||
types:
|
||||
- opened
|
||||
- reopened
|
||||
- edited
|
||||
- synchronize
|
||||
- labeled
|
||||
|
@ -16,6 +14,15 @@ jobs:
|
|||
steps:
|
||||
- uses: https://code.forgejo.org/actions/checkout@v3
|
||||
|
||||
- name: event
|
||||
run: |
|
||||
cat <<'EOF'
|
||||
${{ toJSON(github.event.pull_request.labels.*.name) }}
|
||||
EOF
|
||||
cat <<'EOF'
|
||||
${{ toJSON(github.event) }}
|
||||
EOF
|
||||
|
||||
- uses: https://code.forgejo.org/actions/setup-go@v4
|
||||
with:
|
||||
go-version-file: "go.mod"
|
||||
|
@ -29,4 +36,4 @@ jobs:
|
|||
|
||||
- name: release-notes-assistant preview
|
||||
run: |
|
||||
go run code.forgejo.org/forgejo/release-notes-assistant@v1.0.2 --config .release-notes-assistant.yaml --storage pr --storage-location ${{ github.event.pull_request.number }} --forgejo-url $GITHUB_SERVER_URL --repository $GITHUB_REPOSITORY --token ${{ secrets.RELEASE_NOTES_ASSISTANT_TOKEN }} preview ${{ github.event.pull_request.number }}
|
||||
go run code.forgejo.org/forgejo/release-notes-assistant@v1.0.3 --config .release-notes-assistant.yaml --storage pr --storage-location ${{ github.event.pull_request.number }} --forgejo-url $GITHUB_SERVER_URL --repository $GITHUB_REPOSITORY --token ${{ secrets.RELEASE_NOTES_ASSISTANT_TOKEN }} preview ${{ github.event.pull_request.number }}
|
||||
|
|
Loading…
Reference in a new issue