Problem
When merging branches with conflicts using PhpStorm, the commit message is not being properly populated with the content of .git/MERGE_MESSAGE. Instead, it shows either the previous commit message or an empty message, depending on the Settings > Version Control > Commit > Clear initial commit message setting.
Cause
This issue appears to be project-specific and related to the .idea configuration folder of the affected project. Invalid cache, corrupted configuration files, or a particular setting might be causing the incorrect behavior.
Resolution
-
Verify Behavior on a New Project
- Create a new test project in PhpStorm.
- Make a few commits on separate branches.
- Merge the branches and resolve conflicts.
- Check if the commit message is correctly populated.
- Confirm whether the issue persists only in the initial project.
-
Clear IDE Caches
- Navigate to File > Invalidate Caches....
- Enable options for Clear file system cache and Local History and Clear VCS Log caches and Indexes.
- Click Invalidate and Restart.
-
Recreate Project Configuration
- Close PhpStorm.
- Delete the
.ideafolder and all*.imlfiles in the project's root directory. Backup these files if required. - Re-import the project as explained in Importing a project from existing sources.
Following these steps should help narrow down and resolve the issue with commit message population after a merge with conflicts.
Comments
0 comments
Please sign in to leave a comment.