I want to do an interactive rebase of a branch like:
git rebase -i HEAD~4
Didn't find a way to do this in IntelliJ IDEA. Please advice if this is possible at all. Thank you.
Changing Multiple Commit Messages You can run rebase interactively by adding the -i option to git rebase . You must indicate how far back you want to rewrite commits by telling the command which commit to rebase onto.
Building on top of Git's regular git rebase command, interactive rebasing allows users to modify single commits of the rebased branch by applying transformations such as commit renaming, reordering of all commits, removal of unwanted commits, merging of two or more commits into one, and more.
Interactive rebase in Git is a tool that provides more manual control of your history revision process. When using interactive rebase, you will specify a point on your branch's history, and then you will be presented with a list of commits up until that point.
You can use the given UI features in Intellij IDEA , if you are not much familiar with git rebase -i
commands.
Open version control tab(View -> Tool windows -> Version Control
or using Alt+9
)
goto log tab under version control tool window.
select the commit where you want to start your rebase
right click on the commit and select option interactively rebase from here
Select what you want to do from the dialog box shown and do rebase :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With