Skip to content

Commit

Permalink
enable auto-merge
Browse files Browse the repository at this point in the history
  • Loading branch information
James Wood authored and James Wood committed May 1, 2024
1 parent f1a87a2 commit 033697a
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions .github/workflows/rerun_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

git fetch --all

# Fetch open PRs and enable auto-merge on each one
pr_numbers=$(gh pr list --state open --json number | jq -r '.[].number')

for pr_number in $pr_numbers; do
echo "Auto-merging PR number: $pr_number"
gh pr merge --merge --auto $pr_number
done

gh pr list --state open --label $1 --limit 500 >branches.list
#git branch -r >branches.list

Expand All @@ -13,15 +21,6 @@ cat branches2.list
#git config --global user.email ${{ github.actor }}@users.noreply.github.com
#git config --global user.name "${{ github.actor }}"

# Fetch a list of open pull requests using gh pr list and extract the numbers
pr_numbers=$(gh pr list --state open --json number | jq -r '.[].number')

# Loop through the list of pull request numbers
for pr_number in $pr_numbers; do
echo "Pull Request Number: $pr_number"
gh pr edit $pr_number --auto-merge --merge --squash
done

while read branch; do
echo "Branch: $branch"
git checkout $branch
Expand Down

0 comments on commit 033697a

Please sign in to comment.