gh pr merge

Merge a pull request


Merge a pull request on GitHub.

By default, the head branch of the pull request will get deleted on both remote and local repositories. To retain the branch, use '--delete-branch=false'.

gh pr merge [<number> | <url> | <branch>] [flags]


  -d, --delete-branch   Delete the local and remote branch after merge (default true)
  -m, --merge           Merge the commits with the base branch
  -r, --rebase          Rebase the commits onto the base branch
  -s, --squash          Squash the commits into one commit and merge it into the base branch

Options inherited from parent commands

      --help                     Show help for command
  -R, --repo [HOST/]OWNER/REPO   Select another repository using the [HOST/]OWNER/REPO format