Rename your latest Git commit directly from IntelliJ IDEA. Features a multi-line input dialog and validation to prevent empty commit messages.
- Rename the most recent Git commit via
git commit --amend. - Multi-line commit message support.
- Prevents empty messages with a warning and re-prompt.
- Skips amend if the new message matches the current one.
- Error handling for failed amend attempts.
- Manually: download the latest release and install using Settings/Preferences > Plugins > ⚙️ > Install plugin from disk...
- Git: follow developer guide below.
-
Clone the Repo:
git clone https://github.com/mikolajed/IntelliJ-Git-Plugin.git cd IntelliJ-Git-Plugin -
Open in IntelliJ IDEA:
- Tested on IntelliJ IDEA 2024.3.5 (Ultimate Edition).
- Navigate to File > Open and select the cloned folder.
- Configure Project Structure:
-
Navigate to File > Project Structure
-
Under SDKs, click + > IntelliJ Platform Plugin SDK and choose your IDEA install dir.
-
Add
git4ideato the classpath it might be at a different location. -
Select the SDK > Classpath tab > + > Navigate to <IDEA_DIR>/plugins/git4idea/lib/git4idea.jar > OK.
-
Apply and close.
New project SDK Add Git4Idea to the classpath 

- Gradle Sync:
- File > Sync Project with Gradle Files or click the Gradle elephant icon.
- Wait for dependencies (JUnit 5, Mockito) to resolve.
- Run the Plugin:
- In IDEA: Run > Run 'Plugin'.
- Or via Gradle:
./gradlew runIde- Test It: In the sandbox IDEA instance:
-
Create a simple project.
Plugin location Rename current commit 

-
Init Git:
git init, add files, and create a commit (git commit -m "Initial commit"). -
Navigate to main toolbar > Git > Rename Current Commit and change commit message when prompted.
- Build for Distribution: In case you make any changes w.r.t. current release version, you can build the plugin with:
./gradlew buildPlugin