1
vote
Accepted
How can I match a regexp containing newlines?
I would try:
:execute 'match PrompterCompletion /' . substitute(g:last_completion_text, "[\n\<C-m>]", '\\n', 'g') . '/'
1
vote
Accepted
Neovim paste without overwriting register w/ Lua
I believe you should do:
vim.api.nvim_set_keymap('v', 'p', 'pgvy', { noremap = true })
The first argument is the mode:
n for Normal (equivalent to nnoremap)
v for Visual (equivalent to vnoremap)
...
1
vote
What are the escaping rules of command arguments?
What are the rules that :file arguments are escaped?
The argument to :file is undergoing expand() function. expand() expands wildcards and all special keywords. All special characters % # <, ...
1
vote
How to detect IntelliJ/IdeaVim in vimrc?
Since IdeaVim 1.8.0 you can use the following condition: has("ide"). This works because IdeaVim supports VimScript for several years since 1.7.0.
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
vimscript × 1535vimrc × 249
key-bindings × 129
neovim × 122
functions × 112
regular-expression × 56
autocmd × 51
syntax-highlighting × 48
buffers × 40
search × 38
command-line × 34
variables × 34
gvim × 33
visual-mode × 32
vim-windows × 30
plugin-system × 26
external-command × 25
statusline × 23
cursor-movement × 21
register × 21
lua × 21
terminal × 20
autocompletion × 20
vimscript-python × 20
highlight × 19