Skip to content

Commit

Permalink
approve instead of merge
Browse files Browse the repository at this point in the history
  • Loading branch information
glenn-sorrentino committed Sep 1, 2024
1 parent 2823429 commit d85cb2a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/bypass-css-review.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
exit 1
fi
- name: Check for CSS files and merge if conditions are met
- name: Check for CSS files and approve if conditions are met
run: |
if git diff --name-only main ${{ github.head_ref }} | grep -q '\.css$'; then
echo "CSS files detected and user is an admin, bypassing review requirement"
gh pr merge ${{ github.event.pull_request.number }} --auto --squash
echo "CSS files detected and user is an admin, approving PR"
gh pr review ${{ github.event.pull_request.number }} --approve --body "Approved: CSS file changes detected and user is an admin."
else
echo "No CSS files detected or user is not an admin, continuing with normal review process"
fi
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/bypass-version-review.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
exit 1
fi
- name: Check for hushline/version.py and merge if conditions are met
- name: Check for hushline/version.py and approve if conditions are met
run: |
if git diff --name-only main ${{ github.head_ref }} | grep -q '^hushline/version.py$'; then
echo "hushline/version.py detected and user is an admin, bypassing review requirement"
gh pr merge ${{ github.event.pull_request.number }} --auto --squash
echo "hushline/version.py detected and user is an admin, approving PR"
gh pr review ${{ github.event.pull_request.number }} --approve --body "Approved: hushline/version.py changes detected and user is an admin."
else
echo "No matching files detected or user is not an admin, continuing with normal review process"
fi
Expand Down

0 comments on commit d85cb2a

Please sign in to comment.