Mergify Rebase Command

Rebase a pull request.


The rebase command provides users with an instant method to instruct Mergify to rebase a pull request against its base branch. It’s a handy way to ensure that the pull request is updated with the latest changes from the base branch without manually triggering a rebase.

By leveraging the rebase command, developers can keep their pull requests up-to-date and maintain a clean commit history, enhancing the clarity and quality of the project’s development.

The rebase command provided by Mergify has several advantages over the native GitHub rebase feature:

  • Rebases are done using the --autosquash option. This mean commits starting with fixup!, squash! or other commands will be honored.

  • When the dismiss_reviews action is being used, it will not reset the reviews if the rebase is executed by Mergify.

  • It’s always available, whatever the repository configuration might be.

  • It can be restricted to certain users or teams.

To make use of the rebase command, simply comment on the desired pull request:

@mergifyio rebase
Posting '@mergifyio rebase' in GitHub interface