Composer: Create a git commit for every "Accept all"

It would be helpful to have a functionality so that for every accepted composer solution by “Accept all”, it will create a git commit with the description of the current composer chat.

This way we have a full history of what it was done and the option to revert back to certain snapshots long after the cursor session closes, for every project

3 Likes

+1 up this. would be freaking great.

To sum this up:

When a user selects “Accept all” for a solution provided by the Composer, it would be immensely helpful if Cursor automatically generated a Git commit.

For each commit, I propose:

  • Short Commit Message: A summary of the Composer’s suggested changes.
  • Detailed Commit Description: A full record of the user’s chat request with Composer and/or full record of composer’s suggested changes

This feature would create a comprehensive history of accepted solutions, allowing users to easily track and revert to specific code snapshots, even after the session has ended. It would be especially beneficial for maintaining long-term project histories and ensuring efficient version control.

1 Like

I like this a lot. The Composer does have its checkpointing in there already (in the faint small print). That’s saved me from hallucination hell a few times, but I’ve found the implementation a bit flaky and had the UI get very weird on me. It also seems checkpointing doesn’t persist, so if Cursor does start misbehaving and you decide to restart the app, you bake in whatever mess you got yourself into, with no way to back out of it.

Auto-git would make a great addition to the checkpointing. Keep checkpoints for while you’re stumbling through the mist, and every time you reach a clearing, Accept All and know you can always get back there. +1

2 Likes

Yes, I’d like this as well.

Checkpointing feels like a reinvention of git, which is unnecessary.
Checkpointing also doesn’t work well.
Git does work well.
It also makes sense to use git because 99% of users will be familiar with git and using it as part of their workflow.

I would also find these useful within Composer:

  1. the user can revert the last commit in the current conversation.
  2. the user can revert all commits in the current conversation.
  3. the user can start a new branch with each new chat. It should be auto-named, with the option to edit.
  4. the user can start a new branch within a chat. It should be auto-named, with the option to edit.

Ideally this would all be available for Chat, as well as Composer.