Essentially nvr --nostart --remote-send <keys>
written in Rust.
Run nvim --listen /tmp/nvim.sock
(or for Windows users nvim --listen \\.\pipe\nvim
)
$ cargo install nvim-send
$ nvim-send --remote-send '<esc>:echo "hello"<cr>' --servername /tmp/nvim.sock
MIT/Apache-2.0