PHPStorm AI Assistant commit message mods
I’ve been testing out the Jetbrains AI service the past few months. Used Copilot for a while in 2023, then Codeium for about a year, and am now trying Jetbrains. I can’t say I notice much of a difference for most of the standard code I deal with, but I did recently start using Jetbrains AI with their integrated git client.
I’m generally bad a commit messages, and … have periods of laziness. I use Tower for a lot of git work, and it’s great for some things – letting me ‘undo’ was the thing that got me to buy it in the first place. But… it’s something to switch to, and I … sometimes don’t break out of the zone enough to structure good commits and document them.
The Jetbrains AI tool is OK for code, but has a hook to expose it to their inbuilt git client. Specifically… after you choose files, you can hit a button and it’ll write a commit message describing the changes. And… it’s *pretty good* at finding a decent balance between brevity and explanation. You can edit after it provides a message, but I haven’t found much of a need to.
Except… I picked up a habit of ‘conventional commit’ prefixing in commit messages. The Jetbrains AI doesn’t do that, and… on a recent test project, I was getting used to not having that style. I then found the ‘AI prompts’ section in the settings area, and… there’s a commit message prompt. And it’s editable!
I modified it to ask it to provide a prefix tag like ‘feat:’ or ‘doc:’ or ‘fix:’ or similar, to summarize the type of commit, along with its regular summarization. It worked like a champ the last few days, and I’ll be keeping it around. I’ll be checking out more of the configurable prompts to see what other benefits I can wrangle from this AI service. 🙂