Search highlight is not cleared when there is no match
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- vim
- Domain
- tooling
Research direction
Start by reproducing the issue with the minimal vimrc in Vim, including the multiple-window case, then inspect the plugin's search-highlight handling. Done means moving the cursor clears stale highlighting after a search with no match, both in a single buffer and when another window has a match.
Written by the indexing model from the issue text.
Description
Recently I experienced an issue multiple times. When I search something and there is no match in the current buffer, then search highlight is not cleared even if I move the cursor.
This is the minimal vimrc to reproduce:
set nocompatible
filetype off
call plug#begin()
Plug 'junegunn/vim-slash'
call plug#end()
Open Vim and search anything, for example, /test. Then we'll see E486: Pattern not found: test error. Just insert that text, test to the buffer. Then it'll be immediately highlighted. If I turn off the search highlight, I need to type :noh or search that term again and move the cursor.
This issue is clearer when there are multiple windows open. One having no match, and the other having one match or more. If the current buffer doesn't have a match, then the search highlight of the other is not cleared when I move the cursor.
- Dominant language
- Vim Script
- Stars
- 330
- Forks
- 34
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
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.
More from junegunn/vim-slash
-
`*` incorrectly restores view due to wrapped linesPossibly taken @nkouevda claimed this 1175 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 48/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 1/5 Under an hour Newbie friendliness 55/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
All issues in junegunn/vim-slash
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
drevendev/Devostasis#158 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
vetro-protocol/vetro-monorepo#1277 ·
Maintainers usually reply within 1 day
-
Upgrade psalmOpendependencies
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
-
bug for-agent ready
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
WenyuChiou/agent-board#1812 · 2 comments ·
Maintainers usually reply within 1 day