←back to thread

Making TRAMP faster

(coredumped.dev)
226 points celeritascelery | 1 comments | | HN request time: 0.21s | source
Show context
shwouchk ◴[] No.44357887[source]
tramp is great. all the other mentioned solutions are nowhere near as seamless for “just do what i want, without distractions”.

vscode? “trust me bro, i will run a networked daemon on your server”. enjoy wondering which plugins to reinstall on your remote. enjoy installing proprietary shareware+telemetry plugins just to use git. try opening a local file and a remote file side by side in the same window. wifi connection broke for a sec? oops, you have to refresh the whole browser window.

want to edit a single file on a host you rarely connect to? enjoy spending 10 minutes setting up autosync solutions.

with any of the above - oops, you actually need sudo for that file in /etc? yeah, drop to shell and edit in vim.

there are other options to do stuff and for very specific predefined workflows they may win, but the versatility of tramp is still unmatched, especially if you do use emacs.

the only times ive had issues is when i have a weird shell setup on the remote - for that there is /sshx: instead of /ssh:

replies(2): >>44359279 #>>44366365 #
graemep ◴[] No.44359279[source]
What about mounting a remote file system over sftp? Install EMACS or whatever editor you prefer on the remote?
replies(2): >>44359784 #>>44361778 #
shwouchk ◴[] No.44361778[source]
installing an editor on the remote sure works - my mention of vim was not an accident, it is my preferred remote editor. some of us are bitextual ;-) - but then you lose the seamless remote+local editing, need to sync your config, potentially clash with someone else’s (ever ssh into ubuntu@awshost?), take special care not to sync any private stuff, etc.

as for sftp, unfortunately that’s not an option if you happen to use windows locally eg for work reasons, nor if you use a mac as of several years now, since fuse became closed source.

not to mention, again, the fact that you are limited to whatever root you decided to mount, limited to editing as a user that i’ve already mentioned, as well as limited from using remote tools as sibling stated. try making a git commit over sftp.

if you have a focused “working on a project” workflow it may work, otherwise PITA

replies(1): >>44363687 #
graemep ◴[] No.44363687[source]
I suppose I fail to see the advantages because I have never had a need to keep remote and local synced as I go. Its always been work on local and sync to remote, with editing on a remote for very specific and limited things.
replies(1): >>44365247 #
1. shwouchk ◴[] No.44365247[source]
i was replying to “install your preferred editor on the remote” - without syncing your config, you might as well just use vim even if it’s not your favorite.

most of my remote editing fits into your description. of course, if you’re not an emacs user, you likely won’t find much value in tramp, magit, org-mode, dired, ediff, eshell, etc