neovim has partial support for lua, specifically LuaJIT. This looks like a possibly great way to replace vimscript, because why not?
tested with NVIM v0.5.0-678-ga621c45ba
Proposed but not yet implemented.
All your set XXX
, set XYZ=abc
can be represented as vim.o.XXX
, vim.wo.YYY
, vim.bo.ZZZ
.
vim.o.*
won't error with unknown options
but also (currently) won't work with all options.
Why not use the new built in support for loading vim packages? this uses minpac.
The differences in calling method appear to be because they are builtin vs functions.
1vim.cmd('packadd minpac')
2vim.fn['minpac#add']('k-takata/minpac', {type = 'opt'})
augroups live in nvim_exec
and functions in nvim_command
.
Not quite sure why they need to be different.
nvim_set_keymap
works, but not sure what cnoreabbrev
turns into.