SchoofsKelvin / vscode-sshfs

Extension for Visual Studio Code: File system provider using SSH
GNU General Public License v3.0
543 stars 36 forks source link

Running a code file in Remote SSH Terminal directly from the menu #307

Closed candancaner closed 2 years ago

candancaner commented 2 years ago

Is there a way to run a code file (specifically a Python code for example), directly from the file explorer? I have noticed that we can open a remote terminal within folders, but not in the file level. It would be great to add a new button such as "Run in Remote Terminal" to the menu.

SchoofsKelvin commented 2 years ago

The extension adds a new ssh-shell task type you can use: Screenshot You can also use variables such as ${remoteFile} and ${remoteWorkspaceFolder} (basically ${file} and ${workspaceFolder} but for ssh:// URIs) to target the currently opened file. See #232 for more info about that.