But serious question though: what workflow do you have that remote code editing is necessary?
I agree that remote code editing is not strictly necessary since you can perform such task with sshfs or git push/pull workflows.
On the other hand, having the remote environment in your local IDE quickens the development and you don't have to setup a full replica of your environment locally.
edit: ML/DL here stands for Machine Learning/Deep Learning
Also doing any Git action (git commit or so) over SSHFS is way too slow because it needs to go through the whole project directory. Maybe it's fine if the repo and project is smaller. But in this case, a Git commit can easily take a minute (while locally it takes a few milliseconds).
A Git push/pull workflow would also be quite annoying when you are prototyping and just want to try out things.
Since it needs to do an incremental build to provide any of the intelligent tools for Rust, it means editing directly on the Surface Go degrades to a text editor experience, while doing the remote editing lets the IDE-like features work.
I wrote a bit more about my setup here: https://mtlynch.io/building-a-vm-homelab/
I want to work on code which runs there in the cluster.
I could have a local Git checkout of the code (partly). But sometimes it's a lot of trial and error, and it would be quite annoying to keep extra care that my local Git checkout gets synchronized with the copy in the cluster. Sometimes it might also have other files as dependencies which are simply only there in the cluster - or it would be extremely complicated to replicated all the same locally, and keep it all in sync. Even if PyCharm could help on the syncing part, it would still not be perfect, and would be annoying.
VS Code Remote SSH is basically perfect and exactly like I want it. The only problem is that I still prefer PyCharm.
For starters, there seems to be more than one way to do it - one of the responses below refers to remote-mounting the filesystem using SSHFS, but another way to do it is through the Tools -> Deployment menu. The SSHFS approach is presumably the better one if your particular problem is trying to write code across several machines; the Tools -> Deployment avenue seems much better suited an actual deployment (it is, after all, in the name).
It's got me wondering whether I could get away with doing all my Python development in VS Code but obviously everyone has different constraints.
Here's an example of how Databricks improved their dev cycle with beefy machines running Bazel + remote cache: https://databricks.com/blog/2019/02/27/speedy-scala-builds-w...
In Pycharm, you don't just open remote files via SSH, the files are actually stored on the local machine. The point is to run the interpreter and the debugger on the remote machine.
This allows an integrated workflow with access to things you might not have on the local dev machine.
If your workflow is editing files in Vim / Sublime Code / whatever and then running them from the command line, I guess there really isn't that much benefit to this.
Examples:
- Access to some firewalled-off machine - Load big amounts of data from another machine while your dev machine is on a low bandwidth connection - Access hardware you might not have locally, such as a big GPU while coding on a light laptop
It's basically this feature request: https://youtrack.jetbrains.com/issue/IDEA-226455
Maybe they just need a few more votes on it. Or some more popularity.
Or is it just me and most people don't really need this? I'm still not really sure about the optimal remote work setup. Other people might just use Mosh + Tmux + Vim... I heard that Google has some very nice internal web IDE. If there would be a web IDE as powerful as PyCharm and the other JetBrain IDEs, that would also be a nice option.