bugfix/handle-branch-merges-commit-trailers #146
Workflow file for this run
This file contains hidden or 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: "Organisation ruleset test: Common CI" | |
| on: | |
| push: | |
| branches-ignore: | |
| - main | |
| paths: | |
| - .github/workflows/org.common-ci.test.yml | |
| pull_request: | |
| merge_group: | |
| branch_protection_rule: | |
| types: [edited] | |
| jobs: | |
| pre-commit-check: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| steps: | |
| - name: Checkout current repo | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 | |
| with: | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - name: Check if pre-commit hook ran before push 1 | |
| env: | |
| GH_DEBUG: 1 | |
| run: | | |
| gh pr list --search 4cab8236a5506460e5a3984ace07fc3173d417c6 --state merged --json id | |
| gh pr list --search 4cab8236a5506460e5a3984ace07fc3173d417c6 --state merged | |
| is_pr_commit1=$(gh pr list --search 4cab8236a5506460e5a3984ace07fc3173d417c6 --state merged --json id | jq -e '. == []') | |
| echo $is_pr_commit1 | |
| continue-on-error: true | |
| - name: Check if pre-commit hook ran before push 2 | |
| run: | | |
| is_pr_commit2=$(gh pr list --search da48d51bc4e6d0de29ef75bacf30cc8675617eb1 --state merged --json id | jq -e '. == []') | |
| echo $is_pr_commit2 | |
| continue-on-error: true |