nui 0.0.1

Experimental neovim RPC for UI clients
Documentation
use std::process::Stdio;
use tokio::process::Command;

use crate::Neovim;

pub fn from_child(path: impl Into<String>) -> Neovim {
    let mut child = Command::new(path.into())
        .arg("--embed")
        .arg("--headless")
        .arg("--clean")
        .arg("-u")
        .arg("/Users/lucas/Projects/rust-neovim-ui/neovim/examples/simple.lua")
        .arg("/Users/lucas/Projects/rust-neovim-ui/neovim/examples/simple.lua")
        .stdin(Stdio::piped())
        .stdout(Stdio::piped())
        .spawn()
        .unwrap();
    let stdout = child.stdout.take().unwrap();
    let stdin = child.stdin.take().unwrap();

    Neovim::new(stdout, stdin)
}