gh pr update-branch 123 --rebase

Category: GitHub CLI

gh pr update-branch 123 --rebase

Update a PR branch against its base

Merges or rebases the base branch into the PR's head branch so the diff is current. --rebase replays your commits on top of the base instead of creating a merge commit. Useful before merging when the base moved on and conflicts are trivial.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.