In Sublime Text you could archieve remote code execution using following code:
1 2 3 4
In VSC same could be achieved using Tasks functionality. Difference is you couldn’t create global settings, whatever you do will be saved in project you’re working in. Another difference is you could write something in console and it will be sent over to script’s STDIN, which is unachiavable in Sublime Text.
To start, open your project task configuration file via Ctrl+P, >Configure Task Runner, Others. Then paste following json text and customize it for yourself:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
What will it do? Copy current open file to server’s home (~) folder using rsync (non-verbose mode, add -v in case of trouble), then make it executable and run it via ssh.