contour
contour copied to clipboard
Improve normal mode commands and yank
I often try e.g. `yw`, `y$`, `ytx`, `yi"` (though the last two might be from a plugin)
Originally posted by @cqexbesd in https://github.com/contour-terminal/contour/issues/969#issuecomment-1374945262
Actually, yi" is a standard motion from core vim (and working in Contour already). Not so sure about ytx, that should yank upu until the next x to the right on the current line. That's a good one.
I was surprised they don't work, because they work as v-commands, e.g. vw / v$ / vi". Going into implementing/fixing this might probably end up refactoring the normal mode commands a bit (for cleaner design).
Checklist of things to add
- [x]
y{motion} - [x] motion
$ - [x] motion:
[count]|(jump to column [count]) - [x] motion:
% - [x] motion:
W - [x] motion:
B - [x] motion:
E - [x] motion:
[[and]] - [x] motion:
[]and][ - [x] motion to jump to mark (usually used for prompts), maybe
[mand]m - [x] motion:
T{char} - [x] motion:
F{char} - [x] motion:
t{char} - [x] motion:
f{char} - [x] motion:
,(repeat last f/t/F/T [count] times into the other direction / reverse) - [x] motion:
;(repeat last f/t/F/T [count] times) - [ ] Test cases for vi motions, and select/yank operations
- [ ] Document somehwhere of what's supported.