Kai Großjohann
Fri, 27 Jul 2001 14:51:53 -0700
On Wed, 25 Jul 2001, Ed Avis wrote: > On Wed, 25 Jul 2001, Kai [iso-8859-1] Großjohann wrote: > >>In particular, Tramp does "cd /some/dir", followed by "ls -la". It >>seems that this would be somewhat difficult to achieve if you prefix >>every command with "fsh"? > > Probably > > % fsh host sh -c 'cd /some/dir; ls -la' > > would do it. But is it worth bothering? I don't know. You are the fsh expert, here ;-) > Somehow it seems cleaner to me to run an external command whose job > is 'get this file' rather than have Emacs run ssh in the background > and send commands to it. A lot of the messiness you talked about > with different versions of ls would not be necessary if there were > also an 'rls' or 'sls' command with a standard set of options. It > would be someone else's problem to deal with any strangeness on the > remote system. Ah, yes. If there was a standard set of commands, I wouldn't be having these problems. But such is the way of portable software -- it has to deal with lots of idiosyncrasies of the machines. > And I got the impression from the web page that internal connection > methods were slower and vaguely deprecated, and that it's preferable > to use the rsh or ssh methods. If you can point me to a spot where you got the `vaguely deprecated' idea, please tell me. I'm pretty sure they are not deprecated. I use the `sm' method ;-) Also, with the inline methods you get more features, such as the multi-hop connection methods. > But if the internal connection methods already reuse connections > (which I think they do), and they're not slow or otherwise broken, > and if fsh is not such a drop-in replacement as I hoped, then it > would probably be better to just update the web page with a note > saying: if your connections take a long time to set up, use an > internal method, because it runs ssh only once and keeps it around. Okay, I will try to make this clear in the manual. >>>I thought that the out-of-band scp and rcp methods would just run >>>scp or rcp to transfer files back and forth, so it would be easy to >>>adapt them to fsh. Does tramp also require an actual prompt on the >>>remote machine, even when files are transferred with scp? >> >>Yes, even then, Tramp requires an actual prompt. It wants to do >>filename completion and dired and stuff. (Also, Tramp supports >>remote RCS and sends "ci" and "co" commands to the remote end.) > > Personally I would feel more comfortable with running a single > command like 'fsh somehost ls' rather than printing commands into a > remote shell (though sometimes that is necessary). But I'm just a > random person, and anyway since the tramp code is already written, > it might as well be used. The advantage of Tramp is that fairly little in the way of extra packages on the remote end are needed. If you can telnet to the host, and there's a uuencode and uudecode there, that's enough, for example. > One question: If you use the rsync connection method, for example, > what happens when tramp needs a directory listing or to check stuff > out from RCS? Tramp _always_ opens a shell connection to the remote end. It sends commands there for filename completion and stuff. So the rsync method would have to work together with rsh or ssh or the like. Only for the actual file transfer is there a difference between the inline and out of band methods. For out of band methods, e.g. rsync, Tramp spawns a noninteractive subprocess (rsync) to do the transfer. kai -- ~/.signature: No such file or directory