ranyitz / newsh

🐚 cross-platform library to execute commands in new shells
MIT License
42 stars 4 forks source link

Support vscode integrated terminal #11

Open nirnatan opened 4 years ago

nirnatan commented 4 years ago

Is it possible to add support for vscode integrated terminal? Currently the command opens 'Terminal' process with the split command

ranyitz commented 4 years ago

@nirnatan I couldn't find a way to do it yet. It needs some investigation.

I'll paste here issues that looks relevant:

Launch task directly into split terminal

How to run a script in a new Integrated Terminal window from an Integrated Terminal window

Provide commands to split the terminal

We can maybe find a workaround using tasks API.

orta commented 4 years ago

/cc @tyriar who might have an idea

Tyriar commented 4 years ago

There would need to be a CLI API to split the terminal which doesn't exists and I don't think has come up before. Additionally we don't allow splitting directionally currently, it just splits depending on the orientation of the terminal.

ranyitz commented 4 years ago

Thanks @orta & @Tyriar!

Additionally we don't allow splitting directionally currently, it just splits depending on the orientation of the terminal

That makes sense to me.

There would need to be a CLI API to split the terminal which doesn't exists and I don't think has come up before

I would love to open an issue if you think that it would be relevant.


It seems that a similar API to the one suggested here is being developed on windows terminal. This can be handy for vscode's integrated terminal as well.

Tyriar commented 4 years ago

@ranyitz yes could you open an in vscode to add a cli? I think it would have to be a subgroup like code terminal split-pane, not just code split-pane as it would pollute the top-level namespace too much. Please include the microsoft/terminal link.

ranyitz commented 4 years ago

Thanks @Tyriar, issue opened - https://github.com/microsoft/vscode/issues/92031