Problem
Uncommitted changes disappear from the Commit tool window, or move to another changelist, after a version control operation was interrupted or the IDE loaded or unloaded plugins. The sections below cover each case; pick the one that matches what happened just before the changes went missing.
Resolution
The commit was canceled while a pre-commit hook ran
This applies to a pre-commit hook that runs lint-staged, for example through husky. lint-staged saves the changes in a backup stash before it runs. When the commit is canceled during the hook, the working tree is reset to the last commit, the changes stay in that stash, and the IDE shows only Commit canceled.
- Open the Commit tool window and select the Stash tab.
- Select the stash created during the canceled commit. The tab lists it under the subject of the last commit; in
git stash listit islint-staged automatic backup. - Click Pop.
Tested on WebStorm 2026.3. Known issue: IJPL-261793.
All changes moved to the active changelist after a plugin update
The files keep their changes; only the changelist assignment is lost. When the IDE loads or unloads a version control plugin without a restart, for example when a plugin update includes the Subversion plugin, it moves every change to the active changelist and leaves the other changelists empty. Reproduced in IntelliJ IDEA 2026.3.
Move the files back to their changelists. Known issue: IJPL-207974.
Changes lost after a merge, a checkout or a freeze
- Uncommitted changes are lost after aborting Smart Checkout merge
- Local History: hard reset to a specific point in history before Git merge
- Changelist restoration after system freeze in PhpStorm
Any other case: Local History
Local History keeps revisions of files independently of Git.
- In the Project tool window, right-click the project root or the affected files and select Local History | Show History.
- Find the change to restore and click Revert on the toolbar.
Local History is cleared when a new version of the IDE is installed. To get it back from the previous version, see Importing Local history from a previous versions. For a deleted project or a damaged disk, see Restoring data from a corrupted disk or deleted project using Local History.
Comments
0 comments
Please sign in to leave a comment.