Search code examples
gitrebaseinteractivegitk

How to create a gitk view which always shows work done so far on an interactive rebase (with -i or --interactive option)


I'm doing an interactive rebase (git rebase -i master while on my_branch).

I'm using a gitk view which shows only particular branches (the Branches & tags field of the Edit view dialog is set to my_branch my_branch-old_version etc.).

This view doesn't show any of the commits or staged or working tree changes that have been done so far on the interactive rebase, which makes it hard to keep track of where I am.

How can I make the view show the work done so far on the interactive rebase?


Solution

  • In the view editing dialog, add the following to the Command to generate more commits to include field at the bottom of the dialog:

    git rev-list --ignore-missing REBASE_HEAD..HEAD
    

    Note also that the steps still remaining to do can be reviewed (and possibly changed) with git rebase --edit-todo