Jumping to mark does not work after `O`
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
Describe the bug
I wanted to recreate some of the vim-unimpaired mappings, in particular, ]<Space and [<Space>.
I quickly came up with both base mapping, and then an idea for cursor position restoration via marks, here's what I've added to vim.normalModeKeyBindingsNonRecursive for ]<Space:
{
"before": ["]", "<Space>"],
"after": ["m", "`", "o", "<Esc>", "`", "`"],
}
Works perfectly fine
and for [<Space>:
{
"before": ["[", "<Space>"],
"after": ["m", "`", "O", "<Esc>", "`", "`"],
}
This mapping, however, despite the difference in only o casing, does not work as expected. It does not jump to the set mark.
It's also probably worth noting that using "k", "o" instead of "O" does not help.
To Reproduce
Paste two of the mappings from above to the vim.normalModeKeyBindingsNonRecursive setting in settings.json.
Expected behavior
Everything is described above.
Environment:
- Extension (VsCodeVim) version: 1.21.4
- VSCode version: 1.57.1
- OS: macOs High Sierra 10.13.6
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue using the two mappings in settings.json, especially the difference between o and O after setting a mark. Trace the normal-mode key handling and mark-jump path for these sequences. Done means the [ mapping returns to the set mark like the ] mapping, with coverage for both cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100