aduros / ai.vim

Generate and edit text in Neovim using OpenAI and GPT.
ISC License
293 stars 24 forks source link

FR: diff with hunkwise accept / reject like cursor.so #20

Open alextes opened 1 year ago

alextes commented 1 year ago

It's a large feature request but playing with https://cursor.so it seems very powerful.

AI refactoring, but instead of just making the editing having to undo / redo to figure out if it is what you want, the editor shows you an interactive diff where you can "accept all", "accept only this chunk" and their reject equivalents.

What do you think?

aduros commented 1 year ago

Sounds amazing to me! Is there any existing code that would facilitate this?

alextes commented 1 year ago

I mean, an MVP would be to rely on gitplugins, for example gitsigns can show hunk previews. Similarly there are many plugins that when they see >>>>HEAD they offer conflict resolution actions. Not quite the same but pretty close. Mm, if I think of more I'll share them here.