Easy way to embed neovim in your application
Clone or download
Latest commit a5aec32 Jan 16, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cmake work on nvim_client Jan 8, 2019
readme upate show image Jan 15, 2019
sample revert .. Jan 16, 2019
template add poll_any Jan 15, 2019
CMakeLists.txt milestone Jan 4, 2019
LICENSE Initial commit Dec 24, 2018
README.md add image in readme Jan 12, 2019
mergelib.ar work on nvim_client Jan 8, 2019
nvim_api.py add notification callback as on_xxxxxx Jan 7, 2019

README.md

libnvc

another cpp nvim msgpack-rpc client.
nvim's rpc interface is convenient but not something you can finish in 10 minutes.

image

#include "libnvc.hpp"

int main()
{
    // start nvim quickly:
    // $ nvim --listen "127.0.0.1:6666"
    libnvc::asio_socket socket;
    if(!socket.connect("localhost", 6666)){
        throw std::runtime_error("failed to connect to localhost:6666");
    }

    libnvc::api_client client(&socket);
    client.nvim_input("$i123<CR>123<ESC>");
    client.nvim_buf_set_name(1, "1234");

build

libnvc use asio and mpack internally but hiden by pimpl.
so there is zero dependenct for user's building environment.

$ git clone https://github.com/etorth/libnvc.git
$ mkdir b && cd b && cmake ../libnvc