File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2929 repo: context.repo.repo,
3030 pull_number: ${{ inputs.pr-number }}
3131 });
32-
32+
3333 // Output the base and head branch names for subsequent steps
3434 core.setOutput('base', pr.base.ref);
3535 core.setOutput('head', pr.head.ref);
@@ -41,11 +41,11 @@ jobs:
4141 # Define the required branch pattern
4242 REQUIRED_BASE="main"
4343 REQUIRED_HEAD="stable"
44-
44+
4545 # Get actual values from the previous step
4646 ACTUAL_BASE="${{ steps.get-pr.outputs.base }}"
4747 ACTUAL_HEAD="${{ steps.get-pr.outputs.head }}"
48-
48+
4949 # Compare actual branches against requirements
5050 if [[ "$ACTUAL_BASE" != "$REQUIRED_BASE" ]] || [[ "$ACTUAL_HEAD" != "$REQUIRED_HEAD" ]]; then
5151 echo "Skipping: PR must be from '$REQUIRED_HEAD' to '$REQUIRED_BASE'. Found $ACTUAL_HEAD -> $ACTUAL_BASE"
6969 repo: context.repo.repo,
7070 pull_number: ${{ inputs.pr-number }}
7171 });
72-
72+
7373 // Check if there is at least one review with the state 'APPROVED'
7474 const approved = reviews.some(review => review.state === 'APPROVED');
7575 if (!approved) {
You can’t perform that action at this time.
0 commit comments