randy3k / Terminus

Bring a real terminal to Sublime Text
https://packagecontrol.io/packages/Terminus
MIT License
1.39k stars 81 forks source link

Open text file from terminus shell into Sublime? #268

Open ahfx opened 3 years ago

ahfx commented 3 years ago

Is it possible to open a text file from terminus into the parent sublime window?

randy3k commented 3 years ago

Just using the subl command?

ahfx commented 3 years ago

That opens the file in a new sublime window. Unless there is a setting I can configure to only open it in an existing window?

ahfx commented 3 years ago

related, It would be useful to be able to add the current directory (from the Terminus Shell) as a folder to the current sublime project

jongiddy commented 3 years ago

Hi @ahfx - for Linux I have a plugin at https://github.com/jongiddy/sublime-gidopen that provides both of these capabilities by right-clicking on the path name in Terminus (or any other view).

gwenzek commented 3 years ago

That opens the file in a new sublime window. Unless there is a setting I can configure to only open it in an existing window?

there is probably an issue with your subl command because by default subl opens in the last active window, which is the window containing Terminus is you are executing it from Terminus. Did you alias subl to subl -w ?