Git commit message generation reads the whole file, not just the stashed changes

I wish Cursor’s commit message generator only considered the stashed changes. Right now, I have unstashed changes in a file that I don’t want included in the current commit, but the generated message still references them.

1 Like

I’m experiencing a similar issue, Cursor isn’t generating the commit message correctly. When I click to generate it, it only outputs ‘Claro, P’ instead of summarizing the actual changes. I’ve restarted the application and switched models, but the problem persists. My system is set to English, but I’ve configured Cursor to generate messages in Brazilian Portuguese (pt-BR). Please see the attached video. Note: ‘Claro, P’ is in Portuguese.

Yes, it is unwise to generate Git Commit messages by referencing all the diffs.

Expect to modify it to git diff --staged, referring to the staged content as context.

I hope the Cursor official can consider this configuration.

I have another problem
Even if I change one line, it thinks the whole file is new and writes the commit message based on that!

Admins/Moderators: This is a long-standing (in the lifetime of Cursor) and annoying bug. This thread should be in the Bug Reports category, not Feedback. Perhaps also edit the title from “stashed” to “staged”.

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.