|
|
|
|
|
by qwertox
35 days ago
|
|
"I actually have a much better idea how to use AI responsibly: Simply don't use Claude to completely vibe code AND COMMIT your code." I usually open a new chat in the ide and ask it to "generate a commit message", then i copy paste it. This means that if my code was written 20% by me and 80% by Google Antigravity, and Claude then adds a Co-Authored-By-line, then i think it's wrong. All it did was generate a commit message. |
|
Here's what I do:
`git commit -p`, which basically shows you chunks of changes and you can confirm whether you want to stage those changes. This forces you to briefly review your changes and allows you to select lines or chunks that you don't want to commit (yet).
Then, you have a lot of context, so then its much easier to compose a commit message. Your editor auto-opens at the end of that, so you type in WHY you made the changes (and if you don't know, at least put WHAT you did), save and close the editor, and that's one commit.
If you skip all of this, the commits are less likely to help you later when you need them.