Skip to content
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

Bug: Remapping of numbers (specifically 0) breaks consecutive counting started with non-remapped number-keys #2831

Closed
davidnorthetal opened this issue Jul 11, 2018 · 4 comments

Comments

@davidnorthetal
Copy link

davidnorthetal commented Jul 11, 2018

Is this a BUG REPORT or FEATURE REQUEST? (choose one):
BUG

I happen to notice that #2793 breaks the count feature, so once I remap 0 to ^, doing something like 20j instead of going 20 lines down, it goes one line down after setting the cursor to the beginning of the current line.

You might argue that works as intended but it is not how Vim behaves, In my vimrc I have simply:

noremap 0 ^
noremap ^ 0

and 20j still jumps down 20 lines fine. while 0 outside of a started count works as expected


in my user-settings I use:

    "vim.normalModeKeyBindings": [
        {
            // 0 => ^
            "before": ["0"],
            "after": ["^"]
        }
    ],
  • Extension Name: vim
  • Extension Version: 0.14.2
  • OS Version: Windows_NT x64 10.0.17134
  • VSCode version: 1.24.1
@davidnorthetal davidnorthetal changed the title Remapping of numbers (specifically 0) breaks consecutive counting with non remapped number-keys Bug: Remapping of numbers (specifically 0) breaks consecutive counting with non remapped number-keys Jul 11, 2018
@davidnorthetal davidnorthetal changed the title Bug: Remapping of numbers (specifically 0) breaks consecutive counting with non remapped number-keys Bug: Remapping of numbers (specifically 0) breaks consecutive counting started with non-remapped number-keys Jul 11, 2018
@dmastylo
Copy link

Experiencing this behavior as well; I find the 0 -> ^ remapping to be pretty popular and this bug is causing jumping to lines with a 0 in them impossible, as it's interpreting the 0 as a BOL movement.

@dmastylo
Copy link

dmastylo commented Nov 9, 2018

Any chance eyes could be put on this? Have been using workarounds for this to navigate around my code for a while.

@davidnorthetal
Copy link
Author

Pretty sure this has been fixed in one of the recent updates. Can not reproduce.

@dmastylo
Copy link

@davidnorthetal, just tried it on my instance and seems to be fixed. Thanks for the update! Now to unlearn the "wrong" method I muscle memory'd for the work around haha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants