mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
[nvim] add functions to workaround some interesting behaviors of vim
This commit is contained in:
parent
a27c05856a
commit
618995cc7f
1 changed files with 5 additions and 0 deletions
|
@ -152,6 +152,11 @@ set commentstring=//%s
|
|||
\|xmap # <Cmd>call <SID>VisualStarSearch('?')<CR>N
|
||||
augroup END
|
||||
|
||||
" <https://vim.fandom.com/wiki/Searching_for_expressions_which_include_slashes#Searching_for_slash_as_normal_text>
|
||||
command! -nargs=+ Search let @/ = escape(<q-args>, '/') | normal /<C-R>/<CR>
|
||||
" <https://vim.fandom.com/wiki/Searching_for_expressions_which_include_slashes#Searching_for_all_characters_as_normal_text>
|
||||
command! -nargs=+ SearchLiteral let @/ = '\V'.escape(<q-args>, '/\') | normal /<C-R>/<CR>
|
||||
|
||||
" }}}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue