vorpal
vorpal copied to clipboard
Vorpal + Vim ? An ability to launch interactive cli app from the vorpal app
Hi,
I'm trying to implement an ability to edit my config file from vorpal. As an editor, I'm using vim. I can launch vim from a regular node.js script like this:
childProcess.spawn('vi', [pathToConfig], {
stdio: 'inherit',
});
and it works fine, but I can't do it from my vorpal app. I'm getting:
Vim: Error reading input, exiting...
1;5202;0c10;rgb:d3d3/d7d7/cfcf11;rgb:2e2e/3434/3636
Vim: Finished.
I've tried vorpal.hide();
before spawning the child process.
I've tried vorpal.exec('exit');
, but it kills a process completely on exit and don't spawn a child process.
Is there a way to spawn an interactive CLI app (such as vim) from the vorpal? Or at lease close vorpal instance, launch vim, and then initialize vorpal again? Thanks