nvim: better behavior for remove highlights from hlsearch
now it just does `noh` instead of `set hlsearch!`
This commit is contained in:
parent
866986c46c
commit
8c94182d19
2 changed files with 3 additions and 15 deletions
|
@ -81,18 +81,6 @@ M.treesitter = function()
|
||||||
move = {
|
move = {
|
||||||
enable = true,
|
enable = true,
|
||||||
set_jumps = true, -- whether to set jumps in the jumplist
|
set_jumps = true, -- whether to set jumps in the jumplist
|
||||||
-- How to read these next keybinds
|
|
||||||
-- first character:
|
|
||||||
-- [ means previous
|
|
||||||
-- ] means next
|
|
||||||
-- second character:
|
|
||||||
-- m means function beginning
|
|
||||||
-- M means function end
|
|
||||||
-- OR
|
|
||||||
-- both the same means start in that direction
|
|
||||||
-- ex: [[ means previous start
|
|
||||||
-- both in opposite directions means end in that way
|
|
||||||
-- ex: [] means previous end
|
|
||||||
goto_next_start = {
|
goto_next_start = {
|
||||||
[']m'] = '@function.outer',
|
[']m'] = '@function.outer',
|
||||||
[']]'] = '@class.outer',
|
[']]'] = '@class.outer',
|
||||||
|
|
|
@ -20,7 +20,7 @@ vim.cmd [[
|
||||||
set wrap
|
set wrap
|
||||||
set linebreak
|
set linebreak
|
||||||
" set guicursor= " always use the block cursor
|
" set guicursor= " always use the block cursor
|
||||||
syntax on
|
syntax enable
|
||||||
set redrawtime=1000 " max syntax highlight time
|
set redrawtime=1000 " max syntax highlight time
|
||||||
set number "relativenumber
|
set number "relativenumber
|
||||||
"autocmd InsertEnter * :set norelativenumber " Automatically toggle line numbers
|
"autocmd InsertEnter * :set norelativenumber " Automatically toggle line numbers
|
||||||
|
@ -75,10 +75,10 @@ vim.cmd [[
|
||||||
command! WQA wqa
|
command! WQA wqa
|
||||||
|
|
||||||
" Press Alt h to toggle highlighting on/off, and show current value.
|
" Press Alt h to toggle highlighting on/off, and show current value.
|
||||||
noremap <M-h> <cmd>set hlsearch! hlsearch?<CR>
|
nnoremap <M-h> <cmd>noh<CR>
|
||||||
|
|
||||||
" Toggle spell check with alt S
|
" Toggle spell check with alt S
|
||||||
noremap <M-S> <cmd>set spell! spell?<CR>
|
nnoremap <M-S> <cmd>set spell! spell?<CR>
|
||||||
|
|
||||||
" find + replace with alt S
|
" find + replace with alt S
|
||||||
nnoremap <M-s> <cmd>%s//g<Left><Left>
|
nnoremap <M-s> <cmd>%s//g<Left><Left>
|
||||||
|
|
Loading…
Add table
Reference in a new issue