Skip to content

build: bump actions/checkout from 3 to 4 (#186) #9

build: bump actions/checkout from 3 to 4 (#186)

build: bump actions/checkout from 3 to 4 (#186) #9

Workflow file for this run

name: Auto Rebase
on:
push:
branches: ["master"]
jobs:
auto-rebase-dependabot-branches:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0 # otherwise, you will fail to push refs to dest repo
- run: |
for ref in $(gh pr list --author 'app/dependabot' --json 'baseRefName,headRefName' | jq -r '.[] | select(.baseRefName == "master") | .headRefName'); do
git checkout "${ref}"
git rebase master
git push origin --force
done
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}