Neovim has an ability to run lua scripts non-interactively with LuaJIT runtime providing many builtin functions , powerful “standard library” and an event-loop for asyncronous processing.
You can learn more about it in Neovim by invoking :help -l
.
Example
Create lemp.lua
:
1local greeting = "Hi!"
2vim.fn.system("notify-send " .. greeting)
3print(greeting)
Run:
nvim -l temp.lua
Hi!
If you have notify-send
available you should see a notification.