Instead of only providing the staged changes as context to the AI for commit message generation, currently Antigravity provides all changed files in a repo to the AI which is lowering the quality of the generated commit messages so much that the feature is unusable.
[BUG] Antigravity commit generation uses unstaged changes for context for commit generation messages
+1 this renders the feature useless imo
Hello,
Thank you for reporting this behavior. Please, try creating a custom rule or workflow (e.g., in .agent/rules/commit.md) that explicitly instructs the agent to “Only consider staged changes when generating commit messages.”
There is no world where this feature would be used any other way, this should be the default inplementation.
Hello @Callan_L,
You are absolutely right. Relying on a custom rule for such a fundamental workflow is not ideal, and the default behavior should inherently prioritize staged changes to ensure high-quality, relevant commit messages. I’ll share this feedback to the engineering team.
Thank you for your patience and helping us improve the Antigravity experience.
Thank you! In the meantime I will try the rule. Loving antigravity, it’s just got some quirks. ![]()
still it does not work. it even try to create .agent/rules/commit.md and .agents/rules/commit.md
still it generates commits messages for unstaged changes and does not follow the rules
I agree, this is annoying.
I’m seeing the same issue. Antigravity’s commit message generator appears to inspect both staged and unstaged tracked files, rather than only the staged diff. This produces inaccurate commit messages whenever I have unrelated work-in-progress changes in the working tree.
Please update Antigravity to match the functionality of the Cursor IDE.
Expected behavior:
Commit message generation should be based only on staged changes, equivalent to git diff --cached / git diff --staged.
Actual behavior:
The generated message includes context from unstaged files, causing the message to describe changes that will not be included in the commit.
Additional issue:
The generated messages are also much too terse, especially for larger commits. For multi-file or large staged diffs, the generator should produce a more informative message with an appropriate summary and, when warranted, a short body describing the major change groups.
Impact:
I have to generate commit messages via the coding agent, which is slow and overkill.
Note:
I would provide this feedback directly via the Antigravity IDE feedback forum, but that feature doesn’t work: Unable to provide feedback from antigravity
Google employees use a different in-house AI IDE instead of Antigravity. If they were using Antigravity, they would already be annoyed by this bug. I wonder what their QA team is doing. ![]()
It’s more a matter of approach. With Gemini 3.1 Pro, you have 2 million context tokens, whereas the beta version had 5 million! With that much context and an unlimited response limit, you can start by uploading a massive application framework, which you can then break down into components using several agents in Antigravity at once.
About four months ago, there was a multi-agent option; today I don’t see it, or maybe I’m looking in the wrong place. Still, this is just a casual musing, because even if they’re doing this with AI, it’s at the highest level of capability, which they likely don’t make commercially available.
While it is very nice if it would works for only the staged files, or even there is a way to set some rules for this feature, but we can workaround until it get fixed!
Here is my setup:
-
Configure Git editor to use Antigravity IDE using
git config --local core.editor “agy-ide --wait” - Add a new keybinding shortcut:
{
"key": "cmd+g c",
"command": "runCommands",
"args": {
"commands": [
{
"command": "workbench.action.terminal.sendSequence",
"args": {
"text": "agy -p \"/fast Analyze the changes (use git --no-pager diff --cached) and write a commit message in Conventional Commits format keep the subject under 50 characters and then replace <message> with your message in the command: (git commit --edit -m <message>) and run the command\"\n",
},
},
],
},
},
Now after you staged some changes, just press Cmd+g c , the agent will generate a message for your staged changes only and then git commit --edit -m <message> will open a tab in the IDE containing the message generated, you can review, edit, and modify the message as much as you like! Note that closing the tab with content will execute the commit! delete all content then close to cancel!
Also, based on current cli flags, there are no way to set agent/model through the non-interactive cli usage, which means you need to enter interactive agy cli and then set agent or model!