Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vorpal + Vim ? An ability to launch interactive cli app from the vorpal app #340

Open
anton-yarchuk opened this issue May 7, 2019 · 0 comments

Comments

@anton-yarchuk
Copy link

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant