VSCodeVim / VSCodeVim/Vim

Is it possible to support map to call incsearch?

Open
#7,837 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

In my work scenario, I need to check the log frequently, so I need to search and locate the first error message frequently.

In vim, I usually set:

map <leader>se /uvm_error<cr>ggn
map <leader>xe /*E<cr>ggn

Is there a way to implement this shortcut key setting in vscode-vim?

I tried it like this:

     {
       "before": ["<leader>","s","e"],
       "commands": ["/uvm_error<cr>ggn"]
     },

But what I get is this result:

Failed to handle key `e`: command '/uvm_error<cr>ggn' not found

It may be possible to call the search function of vscode itself to achieve this, but I think incsearch in vim mode is more useful. Is there a way to achieve my needs?

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

No source file or test is identified in the issue. Start by tracing how vscode-vim handles custom key mappings and commands, then determine whether the requested Vim incsearch behavior can be invoked; done means the leader mappings perform the requested searches without an unknown-command error.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
developer-experience
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 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.