VSCodeVim / VSCodeVim/Vim

Unable to insert character through normal mode mapping

Open
#3,650 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

area/remap
Dominant language
TypeScript
Stars
15.2k
Forks
1.5k
Avg merge
3d 18h
Merged PRs (30d)
6

Description

What I'm trying to do
I'm trying to make a mapping to insert a , at the end of the line from normal mode.

To Reproduce

"vim.normalModeKeyBindingsNonRecursive": [
        {
            "before": [",", ","],
            "after": ["A", ",", "<Esc>"],
        },
],

Expected behavior
Pressing ,, will go to the end of the line and insert a , and go back to normal mode.

  • Issue Type: Bug
  • Extension Name: vim
  • Extension Version: 1.3.0
  • OS Version: Darwin x64 18.2.0
  • VSCode version: 1.32.3

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the configuration from the issue in the VSCodeVim extension and start by tracing normal-mode mapping handling for the before sequence [",", ","]. Done means pressing ,, moves to the line end, inserts a comma, and returns to normal mode without breaking existing mappings.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.