Native cross-platform full feature terminal-based sequence editor for git interactive rebase.

Overview GitHub license Coverage Status

Git Interactive Rebase Tool

Native cross-platform full feature terminal based sequence editor for interactive rebase in Git 1.7.8+.

Git Interactive Rebase Tool

This is the documentation for the development build. For the current stable release, please use the 2.1.x documentation.

Table of Contents



Built and works on Linux, macOS, Windows and BSD.

Set action

Easily set the action to pick, squash, fixup, edit, reword and drop.

Basic operations

Reorder rebase list

Reorder the action list with a single key press.

Reorder items

Multiline modification

Change action and reorder multiple lines at once with visual mode.

Visual mode

Toggle breaks

Toggle breaks

View commit details and diff

View the commit overview, and a full commit diff with a press of a key.

Commit overview

Commit diff

Unicode and Emoji support

Unicode support

Emoji support

Edit exec command

Easily edit the command that is run by an exec command.

exec action command edit

Edit in external editor

Need to do something in your Git editor? Quickly shell out to your editor, make a change and return to the tool.

Shell out to editor


Most systems

git config --global sequence.editor interactive-rebase-tool


Standard Command Prompt

git config --global sequence.editor "'C:/path/to/interactive-rebase-tool.exe'"


GitBash requires the use of winpty in order to work correctly, so to set the editor use:

git config --global sequence.editor "winpty /c/path/to/interactive-rebase-tool.exe"


Windows before version 10 has serious rendering issues with saturated darker colors, such as the blue color that is entirely illegible on modern displays. While it is possible to avoid using saturated colors, a better option is to update the theme using Microsoft's ColorTool.

Temporary Override

You can temporarily use a different sequence editor by using the GIT_SEQUENCE_EDITOR environment variable:

GIT_SEQUENCE_EDITOR=emacs git rebase -i [



interactive-rebase-tool <rebase-todo-filepath>
interactive-rebase-tool --help
interactive-rebase-tool --version

Getting Help

The tool has built-in help that can be accessed by hitting the ? key.

Default Key Bindings

Key bindings can be configured, see configuration for more information.

Key Mode Description
Up All Move selection up
Down All Move selection down
Page Up All Move selection up five lines
Page Down All Move selection down five lines
Home All Move selection to start of list
End All Move selection to home of list
q Normal Abort interactive rebase
Q Normal Immediately abort interactive rebase
w Normal Write interactive rebase file
W Normal Immediately write interactive rebase file
? All Show help
c Normal Show commit information
j All Move selected commit(s) down
k All Move selected commit(s) up
b Normal Toggle break action
p All Set selected commit(s) to be picked
r All Set selected commit(s) to be reworded
e All Set selected commit(s) to be edited
s All Set selected commit(s) to be squashed
f All Set selected commit(s) to be fixed-up
d All Set selected commit(s) to be dropped
E Normal Edit the command of an exec action
v All Enter and exit visual mode
d Diff Show full commit diff
I Normal Insert a new line
Delete All Remove selected lines
Control+z All Undo the previous change
Control+y All Redo the previously undone change


Install Rust

To start developing the project, you will need to install Rust, which can generally be done using rustup.


Debian and derivatives

If you plan to build a release package you will need pkg-config and liblzma-dev. They can be installed using apt:

sudo apt install pkg-config liblzma-dev

Build and run

Use cargo to build and run the project. From the project root run:

# only build
cargo build --release
# build and run
cargo run -- 


Sample rebase todo files can be found in ./test/fixtures.


Automated tests are available for all features and can be run with:



The project uses Clippy to provide additional linting, run with:



This project uses rust-fmt to provide a consistent format. A helpful script will ensure that all files are formatted correctly:



Install Cargo Deb
cargo install cargo-deb
cargo build --release
cargo deb

A deb file will be written to target/debian/interactive-rebase-tool_*.deb.

Related Projects


Git Interactive Rebase Tool is released under the GPLv3 license. See LICENSE.

See Third Party Licenses for licenses of the third-party libraries used by this project.

  • Ellipsis (`…`) in commit message triggers multiple display bugs

    Ellipsis (`…`) in commit message triggers multiple display bugs

    Given this commit message that contains an ellipsis:

    Use URI literals to replace deprecated `Uri.uri("…")` calls

    The UI of girb then:

    • shows [email protected] (with a leading and a trailing space) instead of in the commit message
    • indents the commit message after the one with the ellipsis
    • indents the first empty line (consisting of, visibly, only ~) (but not those after that)

    Screenshot: girb_ellipsis-display-bug

    This was discovered using v1.1.0 and successfully reproduced with v1.2.1.

    bug fixed-in-dev 
    opened by homeworkprod 14
  • Add to package repositories

    Add to package repositories

    I would nice to have this project available everywhere! I don't have the energy (or knowledge) to provide builds for everywhere the tool could be used. If anyone is willing to create a package I would be grateful!

    List taken from ripgrep

    • [x] Debian (.deb)
    • [x] Homebrew
    • [x] FreeBSD (pkg)
    • [ ] Linuxbew
    • [ ] MacPorts
    • [x] Windows Chocolatey
    • [x] Windows Scoop
    • [x] Arch Linux (pacman)
    • [ ] Gentoo (emerge)
    • [ ] Fedora (dnf)
    • [ ] openSUSE (zypper)
    • [ ] Ubuntu (apt - PPA)
    • [ ] OpenBSD (pkg_add)
    • [ ] NetBSD (pkgin)

    If anyone is willing to help please comment below!

    opened by MitMaro 14
  • Show help if there's spare screen space

    Show help if there's spare screen space

    At least in my case, there's often a bunch of unused screen real estate, and displaying the help menu (or changing the display of the Actions: bar at the bottom) would be nice. Sort of like WordStar

    opened by alok 11
  • Windows and/or git bash installation / support ?

    Windows and/or git bash installation / support ?

    I work at a Windows shop. Is Windows supported and are there installation packages? I know that ripgrep and fd have Windows executables as part of their CI builds.

    Maybe relevant: The Windows issue of rebase-editor for this: Which is what I use atm with the mentioned workaround.

    enhancement help wanted windows 
    opened by jnachtigall 11
  • Show diff in PAGER

    Show diff in PAGER

    When using the d command to show a diff, I am sometimes thrown off by the lack of less keybindings. It would be convenient if we could use $PAGER instead of the built in pager to show diffs. Alternatively, adding less keybindings to the diff view would also be acceptable.

    enhancement investigate 
    opened by obsgolem 8
  • Basic implementation of #57

    Basic implementation of #57

    This should give us the basic functionality. It would be nice to eventually parse the raw git diff output so that we could get the data behind a menu. You could view the diff of each file individually.

    opened by SteveParson 8
  • Provide version information in binary

    Provide version information in binary

    Thanks for the nice tool.

    I got confused by .deb release for v0.4.0 whose filename is git-interactive-rebase-tool_0.3.0_amd64.deb (the same as for the v0.3.0).

    The binary itself does neither support the --version command-line option nor seem to tell its version somewhere else.

    So after having downloaded a file git-interactive-rebase-tool_0.3.0_amd64.deb its not clear which version it actually is, both before and after installation.

    I suggest to provide the common --version option and, if possible, correct the .deb filename of the v0.4.0 release retroactively.

    opened by homeworkprod 8
  • Incompatible with git config core.commentChar = auto

    Incompatible with git config core.commentChar = auto

    The core.commentChar git configuration has a special value, auto which automatically selects a comment character based on the content of thing being edited:

    Setting this config breaks this tool:

    hint: Waiting for your editor to close the file... Error reading file, Invalid action: #
    error: There was a problem with the editor 'interactive-rebase-tool'.
    opened by SimonSapin 7
  • Could not execute editor because of core.commentChar

    Could not execute editor because of core.commentChar

    I installed this on macos 10.13 and ubuntu 18.04 via cargo install --git (to get the latest version possible) and set this to be my sequence editor with git config --global sequence.editor interactive-rebase-tool. I get this error when I try to rebase:

    Error reading file, (...)/.git/rebase-merge/git-rebase-todo
    Reason: Invalid action: %
    Could not execute editor

    Changing the binary name from git-interactive-rebase-tool to interactive-rebase-tool didn't help.

    opened by alok 7
  • Getting panic error when trying to view commit full details

    Getting panic error when trying to view commit full details

    hi there! just installed this on my mac via homebrew, started a rebase, looked at a commit (c) and then tried to see the full info (d) and got a crash:

    thread 'main' panicked at 'byte index 21 is not a char boundary; it is inside...

    version info:

    • git version 2.35.1
    • interactive-rebase-tool 2.2.0 (2022-05-01)
    Screen Shot 2022-10-12 at 1 49 56 PM

    it seems specific to the one commit i was looking at, others seem to work ok!

    unfortunately the repo is not open source, but if there's any help i can do get a stack trace or something i'm happy to. seems like a handy tool so i'm hoping i can use it.

    opened by schpet 6
  • Release Version 2.2.0

    Release Version 2.2.0

    The last release was last April, but a lot of changes have been made to the project since then; perhaps at least a new patch release should be published to account for that.

    Release checklist:

    • [x] Update the release* workflows to include latest versions of Ubuntu, Debian (
    • [x] Fix documentation errors (
    • [x] Add supported platforms to the README ( (
    • [x] Test on Windows
    • [x] Test on macOS
    • [x] Test on Linux
    • [x] Update CHANGELOG (
    • [x] Bump Cargo.toml version number (
    • [x] Update README to remove reference to development build (
    • [x] Release crates to
    • [x] Tag new release tag

    Found issues:

    • [x] Resize event flood causes render lag, needs a debounce (
    • [x] Shift + ? not working on Windows (
    • [x] ? key does not work during edit (
    • [x] Home/end missing from diff help (
    • [x] External editor not receiving all inputs (
    opened by clarfonthey 6
  • Bump chrono from 0.4.22 to 0.4.23

    Bump chrono from 0.4.22 to 0.4.23

    Bumps chrono from 0.4.22 to 0.4.23.

    Release notes

    Sourced from chrono's releases.

    0.4.23 is the next 0.4 release of the popular chrono date and time library for Rust. After the 0.4.20-0.4.22 series that brought chrono back to life after a long hiatus, development has been fairly quiet, allowing us to start planning changes for the 0.5.0 release. As such, we've started deprecating some APIs that are likely to be removed in 0.5. If you have any feedback on these changes, please let us know in the issue tracker!


    • Deprecate methods that have an _opt() alternative (#827)
    • Deprecate usage of the Date<Tz> type (#851)


    • Optimize RFC 3339 (and RFC 2822) encoding (#844, thanks to @​conradludgate)
    • Addition and subtraction with the Days type (#784)
    • Add NaiveDateTime::from_timestamp_millis(_opt) (#818, thanks to @​Pscheidl -- backported in #823)
    • Allow for changing TZ variable and cache it for Local timezone (#853)
    • Add optional support for the arbitrary::Arbitrary trait (#849, thanks to @​greyblake and @​asayers)


    • Support tzdb location on AIX (#826)
    • Fix warnings in documentation (#847)

    On behalf of @​esheppa and @​djc, thanks to all contributors!

    • 9e5eb49 Bump version to 0.4.23
    • dc4287a store hash of environment variable
    • 57908e9 allow sharing of the allocated environment variable
    • 84f3c30 move last_changed to the Cache
    • 8bc4139 add bench for Local::now()
    • 22b4d32 Avoid use of deprecated API
    • 77317d5 Deprecate usage of the Date<Tz> type
    • 7ba090d Add TimeZone::with_ymd_and_hms() helper method
    • 03165c8 Move Date::years_since() implementation into NaiveDate
    • 645fca0 chore: apply clippy suggestions for 1.65
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.

    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    opened by dependabot[bot] 0
  • Add arm64 and armhf builds to release

    Add arm64 and armhf builds to release

    Can you provide precompiled binaries for armhf and arm64? Those platforms are increasingly popular with Raspberry PIs, Apple M1 (you can run virtualised linux), etc.

    Looking at the build scripts it seems that you could use qemu-binfmt support and arm64/debian:... docker images to compile for another arch on a existing runners.

    If someone wants to compile binary via docker:

    docker run -v "$PWD/arm64:/cargo" -it --rm arm64v8/rust:bullseye cargo install --root /cargo git-interactive-rebase-tool
    docker run -v "$PWD/armhf:/cargo" -it --rm arm32v7/rust:bullseye cargo install --root /cargo git-interactive-rebase-tool

    Or, just generic way for a current architecture:

    docker run -v "$PWD/cargo:/cargo" -it --rm rust:bullseye cargo install --root /cargo git-interactive-rebase-tool

    Take into account that this will take quite some time on RPI.

    opened by ayufan 1
  • git rebase --edit-todo should not empty the file

    git rebase --edit-todo should not empty the file

    I used git rebase --edit-todo to look at how many commits were left in my rebase, but when i didnt change the file, interactive-rebase-tool cleared the file to abort, and then the rebasing ended, and I had to continue the rebase with a cherry-pick of the remaining commits.

    opened by forivall 5
  • Feature Request: Custom actions on keybinds

    Feature Request: Custom actions on keybinds

    It'd be nice to be able to bind custom keywords to binds The idea is to use it with git-revise, which adds index and cut as available actions

    I've hardcoded support for those in but it'd be better if there was a Custom(String) action or something you could manually bind

    Architecturally this seems a little complicated though

    enhancement investigate 
    opened by dali99 3
  • Doesn't work with xargs anymore

    Doesn't work with xargs anymore


    I'm using your tool for a couple of years now. It's great and helps me a lot in my work. Thanks!

    Recently I have noticed that one of my rebase commands has stopped working:

    echo $COMMIT_HASH | xargs -o git rebase --interactive

    After I run it, the terminal window starts to constantly rerender (multiple times per second) and didn't react to key presses at all. So I have to kill it. I tested it both in the default and iTerm2. I'm using macOS 11.3.1.

    Not sure if it's directly related to xargs or something else. Let me know if you need me to provide more info or check something else.

    bug macOS blocked 
    opened by maltsev 2
Tim Oram
Software Developer, founding member of the Computer Technology Society Newfoundland and Labrador, B.Sc. Computer Science.
Tim Oram
Git Explorer: cross-platform git workflow improvement tool inspired by Magit

Gex Git workflow improvement CLI tool inspired by Magit. This project is still under initial development, but I am actively dogfooding it and features

Peter Hebden 192 Nov 14, 2022
Simple macros to write colored and formatted text to a terminal. Based on `termcolor`, thus also cross-platform.

Bunt: simple macro-based terminal colors and styles bunt offers macros to easily print colored and formatted text to a terminal. It is just a convenie

Lukas Kalbertodt 200 Nov 12, 2022
Cross-platform Rust library for coloring and formatting terminal output

Coloring terminal output Documentation term-painter is a cross-platform (i.e. also non-ANSI terminals) Rust library for coloring and formatting termin

Lukas Kalbertodt 75 Jul 28, 2022
Cross platform terminal library rust

Cross-platform Terminal Manipulation Library Crossterm is a pure-rust, terminal manipulation library that makes it possible to write cross-platform te

crossterm-rs 2k Dec 1, 2022
Alacritty - A fast, cross-platform, OpenGL terminal emulator

Alacritty is a modern terminal emulator that comes with sensible defaults, but allows for extensive configuration. By integrating with other applications, rather than reimplementing their functionality, it manages to provide a flexible set of features with high performance. The supported platforms currently consist of BSD, Linux, macOS and Windows.

Alacritty 43.3k Nov 30, 2022
Cross-platform terminal screen clearing library

ClearScreen Cross-platform terminal screen clearing library. API documentation. Dual-licensed with Apache 2.0 and MIT. Uses Caretaker Maintainership.

null 22 Nov 7, 2022
Cross-platform terminal program to download IEEE journals

IEEE Journal Downloader A cross-platform terminal program which tries to download every article in a specified journal and merge the documents into on

Fong Chien Yoong 18 Jul 23, 2022
A Rust CLI tool that helps you enforce Git policies through Git hooks both server and client side

GitPolicyEnforcer This is a command line utility written in Rust, that helps you utilize Git hooks, to enforce various policies. It currently supports

Vagelis Prokopiou 4 Aug 14, 2022
git-cliff can generate changelog files from the Git history by utilizing conventional commits as well as regex-powered custom parsers.⛰️

git-cliff can generate changelog files from the Git history by utilizing conventional commits as well as regex-powered custom parsers. The changelog template can be customized with a configuration file to match the desired format.

Orhun Parmaksız 4.7k Nov 26, 2022
A git sub-command to view your git repository in the web browser

git-view A git sub-command to view your git repository in the web browser! About Are you also frustrated from moving your hands away from the keyboard

Hamothy 5 Sep 26, 2022
Simple Interactive Terminal Todo App in Rust

todo-rs Simple Interactive Terminal Todo App in Rust Quick Start $ cargo run TODO Controls Keys Description k, j Move cursor up and down Shift+K, Shif

Tsoding 53 Oct 30, 2022
A simple interactive OSC (Open Sound Control) debugger for terminal

oscd, a simple interactive OSC debugger for the terminal by using nom as a lexer/parser, oscd offers auto type casting and support sending multiple osc arguments.

Karnpapon Boonput 5 Oct 19, 2022
A library that creates a terminal-like window with feature-packed drawing of text and easy input handling. MIRROR.

BearLibTerminal provides a pseudoterminal window with a grid of character cells and a simple yet powerful API for flexible textual output and uncompli

Tommy Ettinger 43 Oct 31, 2022
🖥 A feature rich terminal UI file transfer and explorer with support for SCP/SFTP/FTP/S3

?? A feature rich terminal UI file transfer and explorer with support for SCP/SFTP/FTP/S3

Christian Visintin 542 Nov 25, 2022
TMM is a Linux native game modding tool. it allows to install and depoly mods for Linux native and wine games.

Tux Mod Manager TMM is a Linux native mod manager made with the Tauri toolkit. It can install, load, remove and deploy mods for both Linux native and

Mathiew May 117 Nov 27, 2022
Build light & secure cross-platform applications with a web-based UI

Millennium Icon by XFaon. *Stats are from Tauri and may not be fully accurate. Millennium is a cross-platform webview framework written in Rust. With

pyke 18 Nov 21, 2022
Rust-based language and runtime for cross-platform app development

Pax Pax is a cross-platform rendering engine & Rust framework for interactive graphics, animations, and GUIs. Pax extends the Rust programming languag

Pax 62 Nov 18, 2022
Amp: A text editor for your terminal.

Amp: A text editor for your terminal. Heavily inspired by Vi/Vim. Amp aims to take the core interaction model of Vim, simplify it, and bundle in the e

Jordan MacDonald 3.2k Nov 23, 2022