-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide keybindings to jump between differences #33
Comments
When diffing areas, what's used its Vim's built-in "diff mode", and you could jump between changes with |
Thanks for the hint, but that was not exactly what I had in mind. These movements are linewise movements. They jump to the next line that differs. But they don't jump the next difference inside the line. As linediff colors the actual differences in a line I was expecting that it would be possible to jump to the next such difference. But if only the internal vimdiff feature is used, maybe that is not possible. |
I see what you mean, yeah. Unfortunately, the plugin doesn't use anything special other than the built-in vimdiff. Theoretically, I could walk character by character to find the beginning of a syntax group, but that feels outside of the scope of the plugin. I did, however, find a few attempts at a general solution:
If you try some of these options out and they work well for your use cases, but they require some special command, I can add an option to the plugin to use it instead of the built-in diff. |
I think since Vim does the diffing and has all the information about it, the best place to implement such mappings is in Vim itself. It will also make it work not just in this plugin. Please consider bringing it up in https://github.com/vim/vim/issues |
On longer lines (e.g. in logfiles) it may be hard to spot the differences even if they are highlighted.
It would therefore be nice to have some keybindings to jump to the next/prev difference, like
]d
and[d
.The text was updated successfully, but these errors were encountered: