1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-09-24 17:51:14 +02:00

Cancel in progress and show diff when not in PR

This commit is contained in:
Gastón Fournier 2025-08-28 18:57:55 +02:00
parent 0a6850889a
commit 63a840885b
No known key found for this signature in database
GPG Key ID: AF45428626E17A8E

View File

@ -1,5 +1,9 @@
name: OpenAPI Diff
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: true
on:
pull_request:
paths:
@ -123,7 +127,11 @@ jobs:
docker run --rm -t -v $(pwd):/specs:ro tufin/oasdiff changelog --format markdown /specs/openapi-stable.json /specs/openapi-current.json > openapi-diff.txt || true
# then output in a format that is useful when you go inside the job output
docker run --rm -t -v $(pwd):/specs:ro tufin/oasdiff changelog --format githubactions /specs/openapi-stable.json /specs/openapi-current.json
- name: Show OpenAPI diff
if: github.event_name != 'pull_request'
run: cat openapi-diff.txt
- name: Comment on PR with OpenAPI diff
if: github.event_name == 'pull_request'
uses: actions/github-script@v7
with:
script: |