Skip to content

Commit

Permalink
.github: Combine OnPRChanged and OnPRReCheck
Browse files Browse the repository at this point in the history
  • Loading branch information
gtjoseph committed Feb 14, 2025
1 parent 94b4a89 commit 668d8d3
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/OnPRCPCheck.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
name: PRCPCheck
run-name: "PR ${{ github.event.number }} ${{ github.workflow }} by ${{ github.actor }}"
run-name: "PR ${{ github.event.number }} CPCheck by ${{ github.actor }}"
on:
pull_request_target:
types: [ labeled ]

jobs:
PRCPCheck:
name: "run-cpcheck"
if: ${{ github.event.label.name == vars.CHERRY_PICK_TEST_LABEL }}
concurrency:
group: cpcheck-${{ github.base_ref }}-${{ github.ref_name }}
cancel-in-progress: true
name: "run-cpcheck"
uses: asterisk/asterisk-ci-actions/.github/workflows/AsteriskPRCPCheck.yml@main-pr-target
13 changes: 0 additions & 13 deletions .github/workflows/OnPRChanged.yml

This file was deleted.

14 changes: 14 additions & 0 deletions .github/workflows/OnPRCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: PRCheck
run-name: "PR ${{ github.event.number }} Check(${{github.event.action}}) by ${{ github.actor }}"
on:
pull_request_target:
types: [ opened, reopened, synchronize, labeled ]

jobs:
PRCheck:
name: "run-check"
if: ${{ (github.event.action != 'labeled') || (github.event.action == 'labeled' && github.event.label.name == vars.RECHECKPR_LABEL) }}
concurrency:
group: check-${{ github.base_ref }}-${{ github.ref_name }}
cancel-in-progress: true
uses: asterisk/asterisk-ci-actions/.github/workflows/AsteriskPRCheck.yml@main-pr-target
8 changes: 3 additions & 5 deletions .github/workflows/OnPRMergeApproved.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
name: PRMerge
run-name: "PR ${{ github.event.number }} ${{ github.workflow }} by ${{ github.actor }}"
run-name: "PR ${{ github.event.number }} Merge by ${{ github.actor }}"
on:
pull_request_target:
types: [labeled]
types: [ labeled ]

jobs:
PRMerge:
name: "run-merge"
if: contains(fromJSON(vars.MERGE_APPROVED_LABELS), github.event.label.name)
concurrency:
group: merge-${{ github.base_ref }}-${{ github.ref_name }}
cancel-in-progress: true
name: "run-merge"
uses: asterisk/asterisk-ci-actions/.github/workflows/AsteriskPRMerge.yml@main
secrets:
TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 668d8d3

Please sign in to comment.