rickhowe / diffchar.vim

Highlight the exact differences, based on characters and words
http://www.vim.org/scripts/script.php?script_id=4932
MIT License
217 stars 10 forks source link

Support obtain/put #10

Closed alexsimply closed 7 years ago

alexsimply commented 7 years ago

While vim's diff is vastly improved with hightlighting at unit level - the vimdiff obtain (do) and put (dp) still operate on a line diff basis - but replacing based on the currently highlighted unit would greatly improve functionality

Example replace

rickhowe commented 7 years ago

Thank you for your idea and let me try to implement it in my plugin. Maybe 'Do' and 'Dp' commands over a difference unit can be added.

alexsimply commented 7 years ago

Great, thanks for the consideration!

rickhowe commented 7 years ago

I updated to 7.0 and added unit-based do/dp, \g and \p. You can change the keymap for them, and combine them with ]b or [b if necessary. Please try.

alexsimply commented 7 years ago

Having tested this it works perfectly for my use case 👍

Many thanks rickhowe - awesome!