\input texinfo @c -*-texinfo-*-@c %**start of header@setfilename ../info/tramp@settitle TRAMP User Manual@setchapternewpage odd@c %**end of header@c This is *so* much nicer :)@footnotestyle end@c In the Tramp CVS, the version number is auto-frobbed from@c configure.ac, so you should edit that file and run@c "autoconf && ./configure" to change the version number.@c Additionally, flags are set with respect to the Emacs flavor; and@c depending whether Tramp is packaged into (X)Emacs, or standalone.@include trampver.texi@c Macros for formatting a filename.@c trampfn is for a full filename, trampfnmhp means method, host, localname@c were given, and so on.@macro trampfn(method, user, host, localname)@value{prefix}@value{method}@value{user}@@@value{host}@value{postfix}@value{localname}@end macro@copyingCopyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.@quotationPermission is granted to copy, distribute and/or modify this documentunder the terms of the GNU Free Documentation License, Version 1.2 orany later version published by the Free Software Foundation; with noInvariant Sections, with the Front-Cover texts being ``A GNUManual'', and with the Back-Cover Texts as in (a) below. A copy of thelicense is included in the section entitled ``GNU Free DocumentationLicense'' in the Emacs manual.(a) The FSF's Back-Cover Text is: ``You have freedom to copy and modifythis GNU Manual, like GNU software. Copies published by the FreeSoftware Foundation raise funds for GNU development.''This document is part of a collection distributed under the GNU FreeDocumentation License. If you want to distribute this documentseparately from the collection, you can do so by adding a copy of thelicense to the document, as described in section 6 of the license.@end quotation@end copying@c Entries for @command{install-info} to use@dircategory @value{emacsname}@direntry* TRAMP: (tramp). Transparent Remote Access, Multiple Protocol @value{emacsname} remote file access via rsh and rcp.@end direntry@tex@titlepage@title @value{tramp} version @value{trampver} User Manual@author by Daniel Pittman@author based on documentation by Kai Gro@ss{}johann@page@insertcopying@end titlepage@page@end tex@ifnottex@node Top, Overview, (dir), (dir)@top @value{tramp} version @value{trampver} User ManualThis file documents @value{tramp} version @value{trampver}, a remote fileediting package for @value{emacsname}.@value{tramp} stands for `Transparent Remote (file) Access, MultipleProtocol'. This package provides remote file editing, similar to@value{ftppackagename}.The difference is that @value{ftppackagename} uses FTP to transferfiles between the local and the remote host, whereas @value{tramp} uses acombination of @command{rsh} and @command{rcp} or other work-alikeprograms, such as @command{ssh}/@command{scp}.You can find the latest version of this document on the web at@uref{http://www.gnu.org/software/tramp/}.@c Pointer to the other Emacs flavor is necessary only in case of@c standalone installation.@ifset installchapterThe manual has been generated for @value{emacsname}.@ifinfoIf you want to read the info pages for @value{emacsothername}, youshould read in @ref{Installation} how to create them.@end ifinfo@ifhtmlIf you're using the other Emacs flavor, you should read the@uref{@value{emacsotherfilename}, @value{emacsothername}} pages.@end ifhtml@end ifset@ifhtml@ifset jamanualThis manual is also available as a @uref{@value{japanesemanual},Japanese translation}.@end ifsetThe latest release of @value{tramp} is available for@uref{http://ftp.gnu.org/gnu/tramp/, download}, or you may see@ref{Obtaining Tramp} for more details, including the CVS serverdetails.@value{tramp} also has a @uref{http://savannah.gnu.org/projects/tramp/,Savannah Project Page}.@end ifhtmlThere is a mailing list for @value{tramp}, available at@email{tramp-devel@@gnu.org}, and archived at@uref{http://lists.gnu.org/archive/html/tramp-devel/, the@value{tramp} Mail Archive}.@ifhtmlOlder archives are located at@uref{http://sourceforge.net/mailarchive/forum.php?forum=tramp-devel,SourceForge Mail Archive} and@uref{http://www.mail-archive.com/emacs-rcp@@ls6.cs.uni-dortmund.de/,The Mail Archive}.@c in HTML output, there's no new paragraph.@*@*@end ifhtml@insertcopying@end ifnottex@menu* Overview:: What @value{tramp} can and cannot do.For the end user:* Obtaining Tramp:: How to obtain @value{tramp}.* History:: History of @value{tramp}.@ifset installchapter* Installation:: Installing @value{tramp} with your @value{emacsname}.@end ifset* Configuration:: Configuring @value{tramp} for use.* Usage:: An overview of the operation of @value{tramp}.* Bug Reports:: Reporting Bugs and Problems.* Frequently Asked Questions:: Questions and answers from the mailing list.* Concept Index:: An item for each concept.For the developer:* Version Control:: The inner workings of remote version control.* Files directories and localnames:: How file names, directories and localnames are mangled and managed.* Issues:: Debatable Issues and What Was Decided.@detailmenu --- The Detailed Node Listing ---@c@ifset installchapterInstalling @value{tramp} with your @value{emacsname}* Installation parameters:: Parameters in order to control installation.* Load paths:: How to plug-in @value{tramp} into your environment.* Japanese manual:: Japanese manual.@end ifsetConfiguring @value{tramp} for use* Connection types:: Types of connections made to remote machines.* Inline methods:: Inline methods.* External transfer methods:: External transfer methods.* Multi-hop Methods:: Connecting to a remote host using multiple hops.* Default Method:: Selecting a default method.* Customizing Methods:: Using Non-Standard Methods.* Customizing Completion:: Selecting config files for user/host name completion.* Password caching:: Reusing passwords for several connections.* Remote Programs:: How @value{tramp} finds and uses programs on the remote machine.* Remote shell setup:: Remote shell setup hints.* Windows setup hints:: Issues with Cygwin ssh.* Auto-save and Backup:: Auto-save and Backup.Using @value{tramp}* Filename Syntax:: @value{tramp} filename conventions.* Multi-hop filename syntax:: Multi-hop filename conventions.* Filename completion:: Filename completion.* Dired:: Dired.* Compilation:: Compile remote files.The inner workings of remote version control* Version Controlled Files:: Determining if a file is under version control.* Remote Commands:: Executing the version control commands on the remote machine.* Changed workfiles:: Detecting if the working file has changed.* Checking out files:: Bringing the workfile out of the repository.* Miscellaneous Version Control:: Things related to Version Control that don't fit elsewhere.Things related to Version Control that don't fit elsewhere* Remote File Ownership:: How VC determines who owns a workfile.* Back-end Versions:: How VC determines what release your RCS is.How file names, directories and localnames are mangled and managed* Localname deconstruction:: Breaking a localname into its components.@end detailmenu@end menu@node Overview@chapter An overview of @value{tramp}@cindex overviewAfter the installation of @value{tramp} into your @value{emacsname},you will be able to access files on remote machines as though theywere local. Access to the remote file system for editing files,version control, and @code{dired} are transparently enabled.Your access to the remote machine can be with the @command{rsh},@command{rlogin}, @command{telnet} programs or with any similarconnection method. This connection must pass @acronym{ASCII}successfully to be usable but need not be 8-bit clean.The package provides support for @command{ssh} connections out of thebox, one of the more common uses of the package. This allowsrelatively secure access to machines, especially if @command{ftp}access is disabled.The majority of activity carried out by @value{tramp} requires only thatthe remote login is possible and is carried out at the terminal. Inorder to access remote files @value{tramp} needs to transfer their contentto the local machine temporarily.@value{tramp} can transfer files between the machines in a variety of ways.The details are easy to select, depending on your needs and themachines in question.The fastest transfer methods (for large files) rely on a remote filetransfer package such as @command{rcp}, @command{scp} or@command{rsync}.If the remote copy methods are not suitable for you, @value{tramp} alsosupports the use of encoded transfers directly through the shell.This requires that the @command{mimencode} or @command{uuencode} toolsare available on the remote machine. These methods are generallyfaster for small files.Within these limitations, @value{tramp} is quite powerful. It is worthnoting that, as of the time of writing, it is far from a polishedend-user product. For a while yet you should expect to run into roughedges and problems with the code now and then.It is finished enough that the developers use it for day to day work butthe installation and setup can be a little difficult to master, as canthe terminology.@value{tramp} is still under active development and any problems you encounter,trivial or major, should be reported to the @value{tramp} developers.@xref{Bug Reports}.@subsubheading Behind the scenes@cindex behind the scenes@cindex details of operation@cindex how it worksThis section tries to explain what goes on behind the scenes when youaccess a remote file through @value{tramp}.Suppose you type @kbd{C-x C-f} and enter part of an @value{tramp} file name,then hit @kbd{@key{TAB}} for completion. Suppose further that this isthe first time that @value{tramp} is invoked for the host in question. Here'swhat happens:@itemize@item@value{tramp} discovers that it needs a connection to the host. So itinvokes @samp{telnet @var{host}} or @samp{rsh @var{host} -l@var{user}} or a similar tool to connect to the remote host.Communication with this process happens through an@value{emacsname} buffer, that is, the output from the remote endgoes into a buffer.@itemThe remote host may prompt for a login name (for @command{telnet}).The login name is given in the file name, so @value{tramp} sends thelogin name and a newline.@itemThe remote host may prompt for a password or pass phrase (for@command{rsh} or for @command{telnet} after sending the login name).@value{tramp} displays the prompt in the minibuffer, asking you for thepassword or pass phrase.You enter the password or pass phrase. @value{tramp} sends it to the remotehost, followed by a newline.@item@value{tramp} now waits for the shell prompt or for a message that the loginfailed.If @value{tramp} sees neither of them after a certain period of time (a minute,say), then it issues an error message saying that it couldn't find theremote shell prompt and shows you what the remote host has sent.If @value{tramp} sees a @samp{login failed} message, it tells you so,aborts the login attempt and allows you to try again.@itemSuppose that the login was successful and @value{tramp} sees the shell promptfrom the remote host. Now @value{tramp} invokes @command{/bin/sh} becauseBourne shells and C shells have different commandsyntaxes.@footnote{Invoking @command{/bin/sh} will fail if your loginshell doesn't recognize @samp{exec /bin/sh} as a valid command.Maybe you use the Scheme shell @command{scsh}@dots{}}After the Bourne shell has come up, @value{tramp} sends a few commands toensure a good working environment. It turns off echoing, it sets theshell prompt, and a few other things.@itemNow the remote shell is up and it good working order. Remember, whatwas supposed to happen is that @value{tramp} tries to find out what files existon the remote host so that it can do filename completion.So, @value{tramp} basically issues @command{cd} and @command{ls} commands andalso sometimes @command{echo} with globbing. Another command that isoften used is @command{test} to find out whether a file is writable or adirectory or the like. The output of each command is parsed for thenecessary operation.@itemSuppose you are finished with filename completion, have entered @kbd{C-xC-f}, a full file name and hit @kbd{@key{RET}}. Now comes the time totransfer the file contents from the remote host to the local host sothat you can edit them.See above for an explanation of how @value{tramp} transfers the file contents.For inline transfers, @value{tramp} issues a command like @samp{mimencode -b/path/to/remote/file}, waits until the output has accumulated in thebuffer that's used for communication, then decodes that output toproduce the file contents.For out-of-band transfers, @value{tramp} issues a command like the following:@examplercp user@@host:/path/to/remote/file /tmp/tramp.4711@end exampleIt then reads the local temporary file @file{/tmp/tramp.4711} into abuffer and deletes the temporary file.@itemYou now edit the buffer contents, blithely unaware of what has happenedbehind the scenes. (Unless you have read this section, that is.) Whenyou are finished, you type @kbd{C-x C-s} to save the buffer.@itemAgain, @value{tramp} transfers the file contents to the remote host eitherinline or out-of-band. This is the reverse of what happens when readingthe file.@end itemizeI hope this has provided you with a basic overview of what happensbehind the scenes when you open a file with @value{tramp}.@c For the end user@node Obtaining Tramp@chapter Obtaining Tramp.@cindex obtaining Tramp@value{tramp} is freely available on the Internet and the latestrelease may be downloaded from@uref{http://ftp.gnu.org/gnu/tramp/}. This release includes the fulldocumentation and code for @value{tramp}, suitable for installation.But GNU Emacs (22 or later) includes @value{tramp} already, and thereis a @value{tramp} package for XEmacs, as well. So maybe it is easierto just use those. But if you want the bleeding edge, readon@dots{...}For the especially brave, @value{tramp} is available from CVS. The CVSversion is the latest version of the code and may contain incompletefeatures or new issues. Use these versions at your own risk.Instructions for obtaining the latest development version of @value{tramp}from CVS can be found by going to the Savannah project page at thefollowing URL and then clicking on the CVS link in the navigation barat the top.@noindent@uref{http://savannah.gnu.org/projects/tramp/}@noindentOr follow the example session below:@example] @strong{cd ~/@value{emacsdir}}] @strong{export CVS_RSH="ssh"}] @strong{cvs -z3 -d:ext:anoncvs@@savannah.gnu.org:/cvsroot/tramp co tramp}@end example@noindentYou should now have a directory @file{~/@value{emacsdir}/tramp}containing the latest version of @value{tramp}. You can fetch the latestupdates from the repository by issuing the command:@example] @strong{cd ~/@value{emacsdir}/tramp}] @strong{export CVS_RSH="ssh"}] @strong{cvs update -d}@end example@noindentOnce you've got updated files from the CVS repository, you need to run@command{autoconf} in order to get an up-to-date @file{configure}script:@example] @strong{cd ~/@value{emacsdir}/tramp}] @strong{autoconf}@end example@node History@chapter History of @value{tramp}@cindex history@cindex development historyDevelopment was started end of November 1998. The package was called@file{rssh.el}, back then. It only provided one method to access afile, using @command{ssh} to log in to a remote host and using@command{scp} to transfer the file contents. After a while, the namewas changed to @file{rcp.el}, and now it's @value{tramp}. Along the way,many more methods for getting a remote shell and for transferring thefile contents were added. Support for VC was added.The most recent addition of major features were the multi-hop methodsadded in April 2000 and the unification of @value{tramp} and Ange-FTPfilenames in July 2002.@c Installation chapter is necessary only in case of standalone@c installation. Text taken from trampinst.texi.@ifset installchapter@include trampinst.texi@end ifset@node Configuration@chapter Configuring @value{tramp} for use@cindex configuration@cindex default configuration@value{tramp} is (normally) fully functional when it is initially installed.It is initially configured to use the @command{ssh} program to connectto the remote host and to use base64 or uu encoding to transfer thefiles through that shell connection. So in the easiest case, you justtype @kbd{C-x C-f} and then enter the filename@file{@value{prefix}@var{user}@@@var{machine}@value{postfix}@var{/path/to.file}}.On some hosts, there are problems with opening a connection. These arerelated to the behavior of the remote shell. See @xref{Remote shellsetup}, for details on this.If you do not wish to use these commands to connect to the remotehost, you should change the default connection and transfer methodthat @value{tramp} uses. There are several different methods that @value{tramp}can use to connect to remote machines and transfer files(@pxref{Connection types}).If you don't know which method is right for you, see @xref{DefaultMethod}.@menu* Connection types:: Types of connections made to remote machines.* Inline methods:: Inline methods.* External transfer methods:: External transfer methods.* Multi-hop Methods:: Connecting to a remote host using multiple hops.* Default Method:: Selecting a default method. Here we also try to help those who don't have the foggiest which method is right for them.* Customizing Methods:: Using Non-Standard Methods.* Customizing Completion:: Selecting config files for user/host name completion.* Password caching:: Reusing passwords for several connections.* Remote Programs:: How @value{tramp} finds and uses programs on the remote machine.* Remote shell setup:: Remote shell setup hints.* Windows setup hints:: Issues with Cygwin ssh.* Auto-save and Backup:: Auto-save and Backup.@end menu@node Connection types@section Types of connections made to remote machines.@cindex connection types, overviewThere are two basic types of transfer methods, each with its ownadvantages and limitations. Both types of connection make use of aremote shell access program such as @command{rsh}, @command{ssh} or@command{telnet} to connect to the remote machine.This connection is used to perform many of the operations that @value{tramp}requires to make the remote file system transparently accessible fromthe local machine. It is only when visiting files that the methodsdiffer.@cindex inline methods@cindex external transfer methods@cindex external methods@cindex out-of-band methods@cindex methods, inline@cindex methods, external transfer@cindex methods, out-of-bandLoading or saving a remote file requires that the content of the filebe transfered between the two machines. The content of the file can betransfered over the same connection used to log in to the remotemachine or the file can be transfered through another connection usinga remote copy program such as @command{rcp}, @command{scp} or@command{rsync}. The former are called @dfn{inline methods}, thelatter are called @dfn{out-of-band methods} or @dfn{external transfermethods} (@dfn{external methods} for short).The performance of the external transfer methods is generally betterthan that of the inline methods, at least for large files. This iscaused by the need to encode and decode the data when transferringinline.The one exception to this rule are the @command{scp} based transfermethods. While these methods do see better performance when actuallytransferring files, the overhead of the cryptographic negotiation atstartup may drown out the improvement in file transfer times.External transfer methods should be configured such a way that theydon't require a password (with @command{ssh-agent}, or such alike).If it isn't possible, you should consider @ref{Password caching},otherwise you will be prompted for a password every copy action.@cindex multi-hop methods@cindex methods, multi-hopA variant of the inline methods are the @dfn{multi-hop methods}.These methods allow you to connect a remote host using a number `hops',each of which connects to a different host. This is useful if you arein a secured network where you need to go through a bastion host toconnect to the outside world.@node Inline methods@section Inline methods@cindex inline methods@cindex methods, inlineThe inline methods in @value{tramp} are quite powerful and can work insituations where you cannot use an external transfer program to connect.Inline methods are the only methods that work when connecting to theremote machine via telnet. (There are also strange inline methods whichallow you to transfer files between @emph{user identities} rather thanhosts, see below.)These methods depend on the existence of a suitable encoding anddecoding command on remote machine. Locally, @value{tramp} may be able touse features of @value{emacsname} to decode and encode the files orit may require access to external commands to perform that task.@cindex uuencode@cindex mimencode@cindex base-64 encoding@value{tramp} checks the availability and usability of commands like@command{mimencode} (part of the @command{metamail} package) or@command{uuencode} on the remote host. The first reliable commandwill be used. The search path can be customized, see @ref{RemotePrograms}.If both commands aren't available on the remote host, @value{tramp}transfers a small piece of Perl code to the remote host, and tries toapply it for encoding and decoding.@table @asis@item @option{rsh}@cindex method rsh@cindex rsh methodConnect to the remote host with @command{rsh}. Due to the unsecureconnection it is recommended for very local host topology only.On operating systems which provide the command @command{remsh} insteadof @command{rsh}, you can use the method @option{remsh}. This is truefor HP-UX or Cray UNICOS, for example.@item @option{ssh}@cindex method ssh@cindex ssh methodConnect to the remote host with @command{ssh}. This is identical tothe previous option except that the @command{ssh} package is used,making the connection more secure.There are also two variants, @option{ssh1} and @option{ssh2}, thatcall @samp{ssh -1} and @samp{ssh -2}, respectively. This way, you canexplicitly select whether you want to use the SSH protocol version 1or 2 to connect to the remote host. (You can also specify in@file{~/.ssh/config}, the SSH configuration file, which protocolshould be used, and use the regular @option{ssh} method.)Two other variants, @option{ssh1_old} and @option{ssh2_old}, use the@command{ssh1} and @command{ssh2} commands explicitly. If you don'tknow what these are, you do not need these options.All the methods based on @command{ssh} have an additional kludgyfeature: you can specify a host name which looks like @file{host#42}(the real host name, then a hash sign, then a port number). Thismeans to connect to the given host but to also pass @code{-p 42} asarguments to the @command{ssh} command.@item @option{telnet}@cindex method telnet@cindex telnet methodConnect to the remote host with @command{telnet}. This is as unsecureas the @option{rsh} method.@item @option{su}@cindex method su@cindex su methodThis method does not connect to a remote host at all, rather it usesthe @command{su} program to allow you to edit files as another user.@item @option{sudo}@cindex method sudo@cindex sudo methodThis is similar to the @option{su} method, but it uses @command{sudo}rather than @command{su} to become a different user.Note that @command{sudo} must be configured to allow you to start ashell as the user. It would be nice if it was sufficient if@command{ls} and @command{mimencode} were allowed, but that is noteasy to implement, so I haven't got around to it, yet.@item @option{sshx}@cindex method sshx@cindex sshx methodAs you would expect, this is similar to @option{ssh}, only a littledifferent. Whereas @option{ssh} opens a normal interactive shell onthe remote host, this option uses @samp{ssh -t -t @var{host} -l@var{user} /bin/sh} to open a connection. This is useful for userswhere the normal login shell is set up to ask them a number ofquestions when logging in. This procedure avoids these questions, andjust gives @value{tramp} a more-or-less `standard' login shell to workwith.Note that this procedure does not eliminate questions asked by@command{ssh} itself. For example, @command{ssh} might ask ``Are yousure you want to continue connecting?'' if the host key of the remotehost is not known. @value{tramp} does not know how to deal with such aquestion (yet), therefore you will need to make sure that you can login without such questions.This is also useful for Windows users where @command{ssh}, wheninvoked from an @value{emacsname} buffer, tells them that it is notallocating a pseudo tty. When this happens, the login shell is wontto not print any shell prompt, which confuses @value{tramp} mightily.For reasons unknown, some Windows ports for @command{ssh} require thedoubled @samp{-t} option.This supports the @samp{-p} kludge.@item @option{krlogin}@cindex method krlogin@cindex km krlogin@cindex Kerberos (with krlogin method)This method is also similar to @option{ssh}. It only uses the@command{krlogin -x} command to log in to the remote host.@item @option{plink}@cindex method plink@cindex plink methodThis method is mostly interesting for Windows users using the PuTTYimplementation of SSH. It uses @samp{plink -ssh} to log in to theremote host.Additionally, the method @option{plink1} is provided, which calls@samp{plink -1 -ssh} in order to use SSH protocol version 1explicitely.CCC: Do we have to connect to the remote host once from the commandline to accept the SSH key? Maybe this can be made automatic?CCC: Does @command{plink} support the @samp{-p} option? @value{tramp} willsupport that, anyway.@end table@node External transfer methods@section External transfer methods@cindex methods, external transfer@cindex methods, out-of-band@cindex external transfer methods@cindex out-of-band methodsThe external transfer methods operate through multiple channels, usingthe remote shell connection for many actions while delegating filetransfers to an external transfer utility.This saves the overhead of encoding and decoding that multiplexing thetransfer through the one connection has with the inline methods.If you want to use an external transfer method you should be able toexecute the transfer utility to copy files to and from the remotemachine without any interaction.@cindex ssh-agentThis means that you will need to use @command{ssh-agent} if you use the@command{scp} program for transfers, or maybe your version of@command{scp} accepts a password on the command line.@footnote{PuTTY's@command{pscp} allows you to specify the password on the command line.}If you use @command{rsync} via @command{ssh} then the same rule mustapply to that connection.If you cannot get an external method to run without asking for apassword you should consider @ref{Password caching}.@table @asis@item @option{rcp} --- @command{rsh} and @command{rcp}@cindex method rcp@cindex rcp method@cindex rcp (with rcp method)@cindex rsh (with rcp method)This method uses the @command{rsh} and @command{rcp} commands to connectto the remote machine and transfer files. This is probably the fastestconnection method available.The alternative method @option{remcp} uses the @command{remsh} and@command{rcp} commands. It should be applied on machines where@command{remsh} is used instead of @command{rsh}.@item @option{scp} --- @command{ssh} and @command{scp}@cindex method scp@cindex scp method@cindex scp (with scp method)@cindex ssh (with scp method)Using @command{ssh} to connect to the remote host and @command{scp} totransfer files between the machines is the best method for securelyconnecting to a remote machine and accessing files.The performance of this option is also quite good. It may be slower thanthe inline methods when you often open and close small files however.The cost of the cryptographic handshake at the start of an @command{scp}session can begin to absorb the advantage that the lack of encoding anddecoding presents.There are also two variants, @option{scp1} and @option{scp2}, thatcall @samp{ssh -1} and @samp{ssh -2}, respectively. This way, you canexplicitly select whether you want to use the SSH protocol version 1or 2 to connect to the remote host. (You can also specify in@file{~/.ssh/config}, the SSH configuration file, which protocolshould be used, and use the regular @option{scp} method.)Two other variants, @option{scp1_old} and @option{scp2_old}, use the@command{ssh1} and @command{ssh2} commands explicitly. If you don'tknow what these are, you do not need these options.All the @command{ssh} based methods support the kludgy @samp{-p}feature where you can specify a port number to connect to in the hostname. For example, the host name @file{host#42} tells @value{tramp} tospecify @samp{-p 42} in the argument list for @command{ssh}.@item @option{rsync} --- @command{ssh} and @command{rsync}@cindex method rsync@cindex rsync method@cindex rsync (with rsync method)@cindex ssh (with rsync method)Using the @command{ssh} command to connect securely to the remotemachine and the @command{rsync} command to transfer files is almostidentical to the @option{scp} method.While @command{rsync} performs much better than @command{scp} whentransferring files that exist on both hosts, this advantage is lost ifthe file exists only on one side of the connection.The @command{rsync} based method may be considerably faster than the@command{rcp} based methods when writing to the remote system. Readingfiles to the local machine is no faster than with a direct copy.This method supports the @samp{-p} hack.@item @option{scpx} --- @command{ssh} and @command{scp}@cindex method scpx@cindex scpx method@cindex scp (with scpx method)@cindex ssh (with scpx method)As you would expect, this is similar to @option{scp}, only a littledifferent. Whereas @option{scp} opens a normal interactive shell onthe remote host, this option uses @samp{ssh -t -t @var{host} -l@var{user} /bin/sh} to open a connection. This is useful for userswhere the normal login shell is set up to ask them a number ofquestions when logging in. This procedure avoids these questions, andjust gives @value{tramp} a more-or-less `standard' login shell to workwith.This is also useful for Windows users where @command{ssh}, wheninvoked from an @value{emacsname} buffer, tells them that it is notallocating a pseudo tty. When this happens, the login shell is wontto not print any shell prompt, which confuses @value{tramp} mightily.This method supports the @samp{-p} hack.@item @option{pscp} --- @command{plink} and @command{pscp}@cindex method pscp@cindex pscp method@cindex pscp (with pscp method)@cindex plink (with pscp method)@cindex PuTTY (with pscp method)This method is similar to @option{scp}, but it uses the@command{plink} command to connect to the remote host, and it uses@command{pscp} for transferring the files. These programs are partof PuTTY, an SSH implementation for Windows.CCC: Does @command{plink} support the @samp{-p} hack?@item @option{fcp} --- @command{fsh} and @command{fcp}@cindex method fcp@cindex fcp method@cindex fsh (with fcp method)@cindex fcp (with fcp method)This method is similar to @option{scp}, but it uses the @command{fsh}command to connect to the remote host, and it uses @command{fcp} fortransferring the files. @command{fsh/fcp} are a front-end for@command{ssh} which allow for reusing the same @command{ssh} sessionfor submitting several commands. This avoids the startup overhead of@command{scp} (which has to establish a secure connection whenever itis called). Note, however, that you can also use one of the inlinemethods to achieve a similar effect.This method uses the command @samp{fsh @var{host} -l @var{user}/bin/sh -i} to establish the connection, it does not work to just say@command{fsh @var{host} -l @var{user}}.@cindex method fsh@cindex fsh methodThere is no inline method using @command{fsh} as the multiplexingprovided by the program is not very useful in our context. @value{tramp}opens just one connection to the remote host and then keeps it open,anyway.@item @option{ftp}@cindex method ftp@cindex ftp methodThis is not a native @value{tramp} method. Instead of, it forwards allrequests to @value{ftppackagename}.@ifset xemacsThis works only for unified filenames, see @ref{Issues}.@end ifset@item @option{smb} --- @command{smbclient}@cindex method smb@cindex smb methodThis is another not natural @value{tramp} method. It uses the@command{smbclient} command on different Unices in order to connect toan SMB server. An SMB server might be a Samba (or CIFS) server onanother UNIX host or, more interesting, a host running MS Windows. Sofar, it is tested towards MS Windows NT, MS Windows 2000, and MSWindows XP.The first directory in the localname must be a share name on the remotehost. Remember, that the @code{$} character in which default sharesusually end, must be written @code{$$} due to environment variablesubstitution in file names. If no share name is given (i.e. remotedirectory @code{/}), all available shares are listed.Since authorization is done on share level, you will be promptedalways for a password if you access another share on the same host.This can be suppressed by @ref{Password caching}.MS Windows uses for authorization both a user name and a domain name.Because of this, the @value{tramp} syntax has been extended: you canspecify a user name which looks like @code{user%domain} (the real username, then a percent sign, then the domain name). So, to connect tothe machine @code{melancholia} as user @code{daniel} of the domain@code{BIZARRE}, and edit @file{.emacs} in the home directory (share@code{daniel$}) I would specify the filename@file{@value{prefix}smb@value{postfixsinglehop}daniel%BIZARRE@@melancholia@value{postfix}/daniel$$/.emacs}.The domain name as well as the user name are optional. If no username is specified at all, the anonymous user (without passwordprompting) is assumed. This is different from all other @value{tramp}methods, where in such a case the local user name is taken.The @option{smb} method supports the @samp{-p} hack.@strong{Please note:} If @value{emacsname} runs locally under MSWindows, this method isn't available. Instead of, you can use UNCfile names like @file{//melancholia/daniel$$/.emacs}. The onlydisadvantage is that there's no possibility to specify another username.@end table@node Multi-hop Methods@section Connecting to a remote host using multiple hops@cindex multi-hop methods@cindex methods, multi-hopSometimes, the methods described before are not sufficient. Sometimes,it is not possible to connect to a remote host using a simple command.For example, if you are in a secured network, you might have to log into a `bastion host' first before you can connect to the outside world.Of course, the target host may also require a bastion host. The formatof multi-hop filenames is slightly different than the format of normal@value{tramp} methods.@cindex method multi@cindex multi methodA multi-hop file name specifies a method, a number of hops, and alocalname (path name on the remote system). The method name is always@option{multi}.Each hop consists of a @dfn{hop method} specification, a user name anda host name. The hop method can be an inline method only. Thefollowing hop methods are (currently) available:@table @option@item telnet@cindex hop method telnet@cindex telnet hop methodUses the well-known @command{telnet} program to connect to the host.Whereas user name and host name are supplied in the file name, theuser is queried for the password.@item rsh@cindex hop method rsh@cindex rsh hop methodThis uses @command{rsh} to connect to the host. You do not need toenter a password unless @command{rsh} explicitly asks for it.The variant @option{remsh} uses the @command{remsh} command. Itshould be applied on machines where @command{remsh} is used instead of@command{rsh}.@item ssh@cindex hop method ssh@cindex ssh hop methodThis uses @command{ssh} to connect to the host. You might have to entera password or a pass phrase.@item su@cindex hop method su@cindex su hop methodThis method does not actually contact a different host, but it allowsyou to become a different user on the host you're currently on. Thismight be useful if you want to edit files as root, but the remote hostdoes not allow remote root logins. In this case you can use@option{telnet}, @option{rsh} or @option{ssh} to connect to theremote host as a non-root user, then use an @option{su} hop to becomeroot. But @option{su} need not be the last hop in a sequence, you couldalso use it somewhere in the middle, if the need arises.Even though you @emph{must} specify both user and host with an@option{su} hop, the host name is ignored and only the user name isused.@item sudo@cindex hop method sudo@cindex sudo hop methodThis is similar to the @option{su} hop, except that it uses@command{sudo} rather than @command{su} to become a different user.@end tableSome people might wish to use port forwarding with @command{ssh} ormaybe they have to use a nonstandard port. This can be accomplishedby putting a stanza in @file{~/.ssh/config} for the account whichspecifies a different port number for a certain host name. But it canalso be accomplished within @value{tramp}, by adding a multi-hop method.For example:@lisp(add-to-list 'tramp-multi-connection-function-alist '("sshf" tramp-multi-connect-rlogin "ssh %h -l %u -p 4400%n"))@end lispNow you can use an @option{sshf} hop which connects to port 4400 instead ofthe standard port.@node Default Method@section Selecting a default method@cindex default method@vindex tramp-default-methodWhen you select an appropriate transfer method for your typical usageyou should set the variable @code{tramp-default-method} to reflect thatchoice. This variable controls which method will be used when a methodis not specified in the @value{tramp} file name. For example:@lisp(setq tramp-default-method "scp")@end lisp@vindex tramp-default-method-alistYou can also specify different methods for certain user/hostcombinations, via the variable @code{tramp-default-method-alist}. Forexample, the following two lines specify to use the @option{ssh}method for all user names matching @samp{john} and the @option{rsync}method for all host names matching @samp{lily}. The third linespecifies to use the @option{su} method for the user @samp{root} onthe machine @samp{localhost}.@lisp(add-to-list 'tramp-default-method-alist '("" "john" "ssh"))(add-to-list 'tramp-default-method-alist '("lily" "" "rsync"))(add-to-list 'tramp-default-method-alist '("\\`localhost\\'" "\\`root\\'" "su"))@end lisp@noindentSee the documentation for the variable@code{tramp-default-method-alist} for more details.External transfer methods are normally preferable to inline transfermethods, giving better performance.@xref{Inline methods}.@xref{External transfer methods}.@xref{Multi-hop Methods}.Another consideration with the selection of transfer methods is theenvironment you will use them in and, especially when used over theInternet, the security implications of your preferred method.The @option{rsh} and @option{telnet} methods send your password asplain text as you log in to the remote machine, as well astransferring the files in such a way that the content can easily beread from other machines.If you need to connect to remote systems that are accessible from theInternet, you should give serious thought to using @option{ssh} basedmethods to connect. These provide a much higher level of security,making it a non-trivial exercise for someone to obtain your passwordor read the content of the files you are editing.@subsection Which method is the right one for me?@cindex choosing the right methodGiven all of the above, you are probably thinking that this is all fineand good, but it's not helping you to choose a method! Right you are.As a developer, we don't want to boss our users around but give themmaximum freedom instead. However, the reality is that some users wouldlike to have some guidance, so here I'll try to give you this guidancewithout bossing you around. You tell me whether it works @dots{}My suggestion is to use an inline method. For large files, out-of-bandmethods might be more efficient, but I guess that most people will wantto edit mostly small files.I guess that these days, most people can access a remote machine byusing @command{ssh}. So I suggest that you use the @option{ssh}method. So, type @kbd{C-x C-f@value{prefix}ssh@value{postfixsinglehop}root@@otherhost@value{postfix}/etc/motd@key{RET}} to edit the @file{/etc/motd} file on the other host.If you can't use @option{ssh} to log in to the remote host, thenselect a method that uses a program that works. For instance, Windowsusers might like the @option{plink} method which uses the PuTTYimplementation of @command{ssh}. Or you use Kerberos and thus like@option{krlogin}.For the special case of editing files on the local host as anotheruser, see the @option{su} or @option{sudo} methods. They offershortened syntax for the @samp{root} account, like@file{@value{prefix}su@value{postfixsinglehop}@value{postfix}/etc/motd}.People who edit large files may want to consider @option{scp} insteadof @option{ssh}, or @option{pscp} instead of @option{plink}. Theseout-of-band methods are faster than inline methods for large files.Note, however, that out-of-band methods suffer from some limitations.Please try first whether you really get a noticeable speed advantagefrom using an out-of-band method! Maybe even for large files, inlinemethods are fast enough.@node Customizing Methods@section Using Non-Standard Methods@cindex customizing methods@cindex using non-standard methods@cindex create your own methodsThere is a variable @code{tramp-methods} which you can change if thepredefined methods don't seem right.For the time being, I'll refer you to the Lisp documentation of thatvariable, accessible with @kbd{C-h v tramp-methods @key{RET}}.@node Customizing Completion@section Selecting config files for user/host name completion@cindex customizing completion@cindex selecting config files@vindex tramp-completion-function-alistThe variable @code{tramp-completion-function-alist} is intended tocustomize which files are taken into account for user and host namecompletion (@pxref{Filename completion}). For every method, it keepsa set of configuration files, accompanied by a Lisp function able toparse that file. Entries in @code{tramp-completion-function-alist}have the form (@var{method} @var{pair1} @var{pair2} ...).Each @var{pair} is composed of (@var{function} @var{file}).@var{function} is responsible to extract user names and host namesfrom @var{file} for completion. There are two functions which accessthis variable:@defun tramp-get-completion-function methodThis function returns the list of completion functions for @var{method}.Example:@example(tramp-get-completion-function "rsh") @result{} ((tramp-parse-rhosts "/etc/hosts.equiv") (tramp-parse-rhosts "~/.rhosts"))@end example@end defun@defun tramp-set-completion-function method function-listThis function sets @var{function-list} as list of completion functionsfor @var{method}.Example:@example(tramp-set-completion-function "ssh" '((tramp-parse-sconfig "/etc/ssh_config") (tramp-parse-sconfig "~/.ssh/config"))) @result{} ((tramp-parse-sconfig "/etc/ssh_config") (tramp-parse-sconfig "~/.ssh/config"))@end example@end defunThe following predefined functions parsing configuration files exist:@table @asis@item @code{tramp-parse-rhosts}@findex tramp-parse-rhostsThis function parses files which are syntactical equivalent to@file{~/.rhosts}. It returns both host names and user names, ifspecified.@item @code{tramp-parse-shosts}@findex tramp-parse-shostsThis function parses files which are syntactical equivalent to@file{~/.ssh/known_hosts}. Since there are no user names specifiedin such files, it can return host names only.@item @code{tramp-parse-sconfig}@findex tramp-parse-shostsThis function returns the host nicknames defined by @code{Host} entriesin @file{~/.ssh/config} style files.@item @code{tramp-parse-shostkeys}@findex tramp-parse-shostkeysSSH2 parsing of directories @file{/etc/ssh2/hostkeys/*} and@file{~/ssh2/hostkeys/*}. Hosts are coded in file names@file{hostkey_@var{portnumber}_@var{host-name}.pub}. User namesare always @code{nil}.@item @code{tramp-parse-sknownhosts}@findex tramp-parse-shostkeysAnother SSH2 style parsing of directories like@file{/etc/ssh2/knownhosts/*} and @file{~/ssh2/knownhosts/*}. Thiscase, hosts names are coded in file names@file{@var{host-name}.@var{algorithm}.pub}. User names are always @code{nil}.@item @code{tramp-parse-hosts}@findex tramp-parse-hostsA function dedicated to @file{/etc/hosts} style files. It returnshost names only.@item @code{tramp-parse-passwd}@findex tramp-parse-passwdA function which parses @file{/etc/passwd} like files. Obviously, itcan return user names only.@item @code{tramp-parse-netrc}@findex tramp-parse-netrcFinally, a function which parses @file{~/.netrc} like files.@end tableIf you want to keep your own data in a file, with your own structure,you might provide such a function as well. This function must meetthe following conventions:@defun my-tramp-parse file@var{file} must be either a file name on your host, or @code{nil}. Thefunction must return a list of (@var{user} @var{host}), which aretaken as candidates for user and host name completion.Example:@example(my-tramp-parse "~/.my-tramp-hosts") @result{} ((nil "toto") ("daniel" "melancholia"))@end example@end defun@node Password caching@section Reusing passwords for several connections.@cindex passwordsSometimes it is necessary to connect to the same remote host severaltimes. Reentering passwords again and again would be annoying, whenthe choosen method does not support access without password promptthrought own configuration.By default, @value{tramp} caches the passwords entered by you. They willbe reused next time if a connection needs them for the same user nameand host name, independant of the connection method.@vindex password-cache-expiryPasswords are not saved permanently, that means the password cachingis limited to the lifetime of your @value{emacsname} session. Youcan influence the lifetime of password caching by customizing thevariable @code{password-cache-expiry}. The value is the number ofseconds how long passwords are cached. Setting it to @code{nil}disables the expiration.@findex tramp-clear-passwdA password is removed from the cache if a connection isn't establishedsuccessfully. You can remove a password from the cache also byexecuting @kbd{M-x tramp-clear-passwd} in a buffer containing arelated remote file or directory.@vindex password-cacheIf you don't like this feature for security reasons, password cachingcan be disabled totally by customizing the variable@code{password-cache} (setting it to @code{nil}).Implementation Note: password caching is based on the packagepassword.el in No Gnus. For the time being, it is activated only whenthis package is seen in the @code{load-path} while loading @value{tramp}.@ifset installchapterIf you don't use No Gnus, you can take password.el from the @value{tramp}@file{contrib} directory, see @ref{Installation parameters}.@end ifsetIt will be activated mandatory once No Gnus has found its way into@value{emacsname}.@node Remote Programs@section How @value{tramp} finds and uses programs on the remote machine.@value{tramp} depends on a number of programs on the remote host in order tofunction, including @command{ls}, @command{test}, @command{find} and@command{cat}.In addition to these required tools, there are various tools that may berequired based on the connection method. See @ref{Inline methods} and@ref{External transfer methods} for details on these.Certain other tools, such as @command{perl} (or @command{perl5}) and@command{grep} will be used if they can be found. When they areavailable, they are used to improve the performance and accuracy ofremote file access.@vindex tramp-remote-pathWhen @value{tramp} connects to the remote machine, it searches for theprograms that it can use. The variable @var{tramp-remote-path} controlsthe directories searched on the remote machine.By default, this is set to a reasonable set of defaults for mostmachines. It is possible, however, that your local (or remote ;) systemadministrator has put the tools you want in some obscure localdirectory.In this case, you can still use them with @value{tramp}. You simply need toadd code to your @file{.emacs} to add the directory to the remote path.This will then be searched by @value{tramp} when you connect and the softwarefound.To add a directory to the remote search path, you could use code suchas:@lisp@i{;; We load @value{tramp} to define the variable.}(require 'tramp)@i{;; We have @command{perl} in "/usr/local/perl/bin"}(add-to-list 'tramp-remote-path "/usr/local/perl/bin")@end lisp@node Remote shell setup@comment node-name, next, previous, up@section Remote shell setup hints@cindex remote shell setup@cindex @file{.profile} file@cindex @file{.login} file@cindex shell init filesAs explained in the @ref{Overview} section, @value{tramp} connects to theremote host and talks to the shell it finds there. Of course, when youlog in, the shell executes its init files. Suppose your init filerequires you to enter the birth date of your mother; clearly @value{tramp}does not know this and hence fails to log you in to that host.There are different possible strategies for pursuing this problem. Onestrategy is to enable @value{tramp} to deal with all possible situations.This is a losing battle, since it is not possible to deal with@emph{all} situations. The other strategy is to require you to set upthe remote host such that it behaves like @value{tramp} expects. This mightbe inconvenient because you have to invest a lot of effort into shellsetup before you can begin to use @value{tramp}.The package, therefore, pursues a combined approach. It tries tofigure out some of the more common setups, and only requires you toavoid really exotic stuff. For example, it looks through a list ofdirectories to find some programs on the remote host. And also, itknows that it is not obvious how to check whether a file exists, andtherefore it tries different possibilities. (On some hosts andshells, the command @command{test -e} does the trick, on some hoststhe shell builtin doesn't work but the program @command{/usr/bin/test-e} or @command{/bin/test -e} works. And on still other hosts,@command{ls -d} is the right way to do this.)Below you find a discussion of a few things that @value{tramp} does not dealwith, and that you therefore have to set up correctly.@table @asis@item @var{shell-prompt-pattern}@vindex shell-prompt-patternAfter logging in to the remote host, @value{tramp} has to wait for the remoteshell startup to finish before it can send commands to the remoteshell. The strategy here is to wait for the shell prompt. In order torecognize the shell prompt, the variable @code{shell-prompt-pattern} hasto be set correctly to recognize the shell prompt on the remote host.Note that @value{tramp} requires the match for @code{shell-prompt-pattern}to be at the end of the buffer. Many people have something like thefollowing as the value for the variable: @code{"^[^>$][>$] *"}. Nowsuppose your shell prompt is @code{a <b> c $ }. In this case,@value{tramp} recognizes the @code{>} character as the end of the prompt,but it is not at the end of the buffer.@item @var{tramp-shell-prompt-pattern}@vindex tramp-shell-prompt-patternThis regular expression is used by @value{tramp} in the same way as@code{shell-prompt-pattern}, to match prompts from the remote shell.This second variable exists because the prompt from the remote shellmight be different from the prompt from a local shell --- after all,the whole point of @value{tramp} is to log in to remote hosts as adifferent user. The default value of@code{tramp-shell-prompt-pattern} is the same as the default value of@code{shell-prompt-pattern}, which is reported to work well in manycircumstances.@item @command{tset} and other questions@cindex Unix command tset@cindex tset Unix commandSome people invoke the @command{tset} program from their shell startupscripts which asks the user about the terminal type of the shell.Maybe some shells ask other questions when they are started. @value{tramp}does not know how to answer these questions. There are two approachesfor dealing with this problem. One approach is to take care that theshell does not ask any questions when invoked from @value{tramp}. You cando this by checking the @code{TERM} environment variable, it will beset to @code{dumb} when connecting.@vindex tramp-terminal-typeThe variable @code{tramp-terminal-type} can be used to change this valueto @code{dumb}.The other approach is to teach @value{tramp} about these questions. Seethe variables @code{tramp-actions-before-shell} and@code{tramp-multi-actions} (for multi-hop connections).@item Environment variables named like users in @file{.profile}If you have a user named frumple and set the variable @code{FRUMPLE} inyour shell environment, then this might cause trouble. Maybe renamethe variable to @code{FRUMPLE_DIR} or the like.This weird effect was actually reported by a @value{tramp} user!@item Non-Bourne commands in @file{.profile}After logging in to the remote host, @value{tramp} issues the command@command{exec /bin/sh}. (Actually, the command is slightlydifferent.) When @command{/bin/sh} is executed, it reads some initfiles, such as @file{~/.shrc} or @file{~/.profile}.Now, some people have a login shell which is not @code{/bin/sh} but aBourne-ish shell such as bash or ksh. Some of these people might puttheir shell setup into the files @file{~/.shrc} or @file{~/.profile}.This way, it is possible for non-Bourne constructs to end up in thosefiles. Then, @command{exec /bin/sh} might cause the Bourne shell tobarf on those constructs.As an example, imagine somebody putting @command{export FOO=bar} intothe file @file{~/.profile}. The standard Bourne shell does notunderstand this syntax and will emit a syntax error when it reachesthis line.Another example is the tilde (@code{~}) character, say when adding@file{~/bin} to @code{$PATH}. Many Bourne shells will not expand thischaracter, and since there is usually no directory whose name consistsof the single character tilde, strange things will happen.What can you do about this?Well, one possibility is to make sure that everything in @file{~/.shrc}and @file{~/.profile} on all remote hosts is Bourne-compatible. In theabove example, instead of @command{export FOO=bar}, you might use@command{FOO=bar; export FOO} instead.The other possibility is to put your non-Bourne shell setup into someother files. For example, bash reads the file @file{~/.bash_profile}instead of @file{~/.profile}, if the former exists. So bashaficionados just rename their @file{~/.profile} to@file{~/.bash_profile} on all remote hosts, and Bob's your uncle.The @value{tramp} developers would like to circumvent this problem, soif you have an idea about it, please tell us. However, we are afraidit is not that simple: before saying @command{exec /bin/sh},@value{tramp} does not know which kind of shell it might be talkingto. It could be a Bourne-ish shell like ksh or bash, or it could be acsh derivative like tcsh, or it could be zsh, or even rc. If theshell is Bourne-ish already, then it might be prudent to omit the@command{exec /bin/sh} step. But how to find out if the shell isBourne-ish?@end table@node Auto-save and Backup@section Auto-save and Backup configuration@cindex auto-save@cindex backup@ifset emacs@vindex backup-directory-alist@end ifset@ifset xemacs@vindex bkup-backup-directory-info@end ifsetNormally, @value{emacsname} writes backup files to the same directoryas the original files, but this behavior can be changed via thevariable@ifset emacs@code{backup-directory-alist}.@end ifset@ifset xemacs@code{bkup-backup-directory-info}.@end ifsetIn connection with @value{tramp}, this can have unexpected side effects.Suppose that you specify that all backups should go to the directory@file{~/.emacs.d/backups/}, and then you edit the file@file{@value{prefix}su@value{postfixsinglehop}root@@localhost@value{postfix}/etc/secretfile}.The effect is that the backup file will be owned by you and not byroot, thus possibly enabling others to see it even if they were notintended to see it.When@ifset emacs@code{backup-directory-alist}@end ifset@ifset xemacs@code{bkup-backup-directory-info}@end ifsetis @code{nil} (the default), such problems do not occur.Therefore, it is usefull to set special values for @value{tramp}files. For example, the following statement effectively `turns off'the effect of@ifset emacs@code{backup-directory-alist}@end ifset@ifset xemacs@code{bkup-backup-directory-info}@end ifsetfor @value{tramp} files:@ifset emacs@lisp(add-to-list 'backup-directory-alist (cons tramp-file-name-regexp nil))@end lisp@end ifset@ifset xemacs@lisp(require 'backup-dir)(add-to-list 'bkup-backup-directory-info (list tramp-file-name-regexp ""))@end lisp@end ifsetAnother possibility is to use the @value{tramp} variable@ifset emacs@code{tramp-backup-directory-alist}.@end ifset@ifset xemacs@code{tramp-bkup-backup-directory-info}.@end ifsetThis variable has the same meaning like@ifset emacs@code{backup-directory-alist}.@end ifset@ifset xemacs@code{bkup-backup-directory-info}.@end ifsetIf a @value{tramp} file is backed up, and DIRECTORY is an absolutelocal file name, DIRECTORY is prepended with the @value{tramp} filename prefix of the file to be backed up.@noindentExample:@ifset emacs@lisp(add-to-list 'backup-directory-alist (cons "." "~/.emacs.d/backups/"))(setq tramp-backup-directory-alist backup-directory-alist)@end lisp@end ifset@ifset xemacs@lisp(require 'backup-dir)(add-to-list 'bkup-backup-directory-info (list "." "~/.emacs.d/backups/" 'full-path))(setq tramp-bkup-backup-directory-info bkup-backup-directory-info)@end lisp@end ifset@noindentThe backup file name of@file{@value{prefix}su@value{postfixsinglehop}root@@localhost@value{postfix}/etc/secretfile}would be@ifset emacs@file{@value{prefix}su@value{postfixsinglehop}root@@localhost@value{postfix}~/.emacs.d/backups/!su:root@@localhost:!etc!secretfile~}@end ifset@ifset xemacs@file{@value{prefix}su@value{postfixsinglehop}root@@localhost@value{postfix}~/.emacs.d/backups/![su!root@@localhost]!etc!secretfile~}@end ifsetThe same problem can happen with auto-saving files.@ifset emacsSince @value{emacsname} 21, the variable@code{auto-save-file-name-transforms} keeps information, on whichdirectory an auto-saved file should go. By default, it is initializedfor @value{tramp} files to the local temporary directory.On some versions of @value{emacsname}, namely the version built forDebian GNU/Linux, the variable @code{auto-save-file-name-transforms}contains the directory where @value{emacsname} was built. Aworkaround is to manually set the variable to a sane value.If auto-saved files should go into the same directory as the originalfiles, @code{auto-save-file-name-transforms} should be set to @code{nil}.Another possibility is to set the variable@code{tramp-auto-save-directory} to a proper value.@end ifset@ifset xemacsFor this purpose you can set the variable @code{auto-save-directory}to a proper value.@end ifset@node Windows setup hints@section Issues with Cygwin ssh@cindex Cygwin, issuesThis section needs a lot of work! Please help.@cindex method sshx with Cygwin@cindex sshx method with CygwinThe recent Cygwin installation of @command{ssh} works only with aCygwinized @value{emacsname}. You can check it by typing @kbd{M-xeshell}, and starting @kbd{ssh test.machine}. The problem is evidentif you see a message like this:@examplePseudo-terminal will not be allocated because stdin is not a terminal.@end exampleOlder @command{ssh} versions of Cygwin are told to cooperate with@value{tramp} selecting @option{sshx} as the connection method. Youcan find information about setting up Cygwin in their FAQ at@uref{http://cygwin.com/faq/}.@cindex method scpx with Cygwin@cindex scpx method with CygwinIf you wish to use the @option{scpx} connection method, then you mighthave the problem that @value{emacsname} calls @command{scp} with aWindows filename such as @code{c:/foo}. The Cygwin version of@command{scp} does not know about Windows filenames and interprets thisas a remote filename on the host @code{c}.One possible workaround is to write a wrapper script for @option{scp}which converts the Windows filename to a Cygwinized filename.@cindex Cygwin and ssh-agent@cindex SSH_AUTH_SOCK and @value{emacsname} on WindowsIf you want to use either @option{ssh} based method on Windows, thenyou might encounter problems with @command{ssh-agent}. Using thisprogram, you can avoid typing the pass-phrase every time you log in.However, if you start @value{emacsname} from a desktop shortcut, thenthe environment variable @code{SSH_AUTH_SOCK} is not set and so@value{emacsname} and thus @value{tramp} and thus @command{ssh} and@command{scp} started from @value{tramp} cannot communicate with@command{ssh-agent}. It works better to start @value{emacsname} fromthe shell.If anyone knows how to start @command{ssh-agent} under Windows in such away that desktop shortcuts can profit, please holler. I don't reallyknow anything at all about Windows@dots{}@node Usage@chapter Using @value{tramp}@cindex using @value{tramp}Once you have installed @value{tramp} it will operate fairly transparently. Youwill be able to access files on any remote machine that you can log into as though they were local.Files are specified to @value{tramp} using a formalized syntax specifying thedetails of the system to connect to. This is similar to the syntax usedby the @value{ftppackagename} package.@cindex type-aheadSomething that might happen which surprises you is that@value{emacsname} remembers all your keystrokes, so if you see apassword prompt from @value{emacsname}, say, and hit @kbd{@key{RET}}twice instead of once, then the second keystroke will be processed by@value{emacsname} after @value{tramp} has done its thing. Why, thistype-ahead is normal behavior, you say. Right you are, but be awarethat opening a remote file might take quite a while, maybe half aminute when a connection needs to be opened. Maybe after half aminute you have already forgotten that you hit that key!@menu* Filename Syntax:: @value{tramp} filename conventions.* Multi-hop filename syntax:: Multi-hop filename conventions.* Filename completion:: Filename completion.* Dired:: Dired.* Compilation:: Compile remote files.@end menu@node Filename Syntax@section @value{tramp} filename conventions@cindex filename syntax@cindex filename examplesTo access the file @var{localname} on the remote machine @var{machine} youwould specify the filename@file{@value{prefix}@var{machine}@value{postfix}@var{localname}}.This will connect to @var{machine} and transfer the file using thedefault method. @xref{Default Method}.Some examples of @value{tramp} filenames are shown below.@table @file@item @value{prefix}melancholia@value{postfix}.emacsEdit the file @file{.emacs} in your home directory on the machine@code{melancholia}.@item @value{prefix}melancholia.danann.net@value{postfix}.emacsThis edits the same file, using the fully qualified domain name ofthe machine.@item @value{prefix}melancholia@value{postfix}~/.emacsThis also edits the same file --- the @file{~} is expanded to yourhome directory on the remote machine, just like it is locally.@item @value{prefix}melancholia@value{postfix}~daniel/.emacsThis edits the file @file{.emacs} in the home directory of the user@code{daniel} on the machine @code{melancholia}. The @file{~<user>}construct is expanded to the home directory of that user on the remotemachine.@item @value{prefix}melancholia@value{postfix}/etc/squid.confThis edits the file @file{/etc/squid.conf} on the machine@code{melancholia}.@end tableUnless you specify a different name to use, @value{tramp} will use thecurrent local user name as the remote user name to log in with. If youneed to log in as a different user, you can specify the user name aspart of the filename.To log in to the remote machine as a specific user, you use the syntax@file{@value{prefix}@var{user}@@@var{machine}@value{postfix}/@var{path/to.file}}.That means that connecting to @code{melancholia} as @code{daniel} andediting @file{.emacs} in your home directory you would specify@file{@value{prefix}daniel@@melancholia@value{postfix}.emacs}.It is also possible to specify other file transfer methods(@pxref{Default Method}) as part of the filename.@ifset emacsThis is done by putting the method before the user and host name, asin@file{@value{prefix}@var{method}@value{postfixsinglehop}}(Note the trailing colon).@end ifset@ifset xemacsThis is done by replacing the initial@file{@value{prefix}} with@file{@value{prefix}<method>@value{postfixsinglehop}}.(Note the trailing slash!).@end ifsetThe user, machine and file specification remain the same.So, to connect to the machine @code{melancholia} as @code{daniel},using the @option{ssh} method to transfer files, and edit @file{.emacs}in my home directory I would specify the filename@file{@value{prefix}ssh@value{postfixsinglehop}daniel@@melancholia@value{postfix}.emacs}.@node Multi-hop filename syntax@section Multi-hop filename conventions@cindex filename syntax for multi-hop files@cindex multi-hop filename syntaxThe syntax of multi-hop file names is necessarily slightly differentthan the syntax of other @value{tramp} file names. Here's an examplemulti-hop file name:@example@value{prefix}multi@value{postfixsinglehop}rsh@value{postfixmultihop}out@@gate@value{postfixsinglehop}telnet@value{postfixmultihop}kai@@real.host@value{postfix}/path/to.file@end exampleThis is quite a mouthful. So let's go through it step by step. Thefile name consists of three parts.@ifset emacsThe parts are separated by colons@end ifset@ifset xemacsThe parts are separated by slashes and square brackets.@end ifsetThe first part is @file{@value{prefix}multi}, the methodspecification. The second part is@file{rsh@value{postfixmultihop}out@@gate@value{postfixsinglehop}telnet@value{postfixmultihop}kai@@real.host}and specifies the hops. The final part is @file{/path/to.file} andspecifies the file name on the remote host.The first part and the final part should be clear. See @ref{Multi-hopMethods}, for a list of alternatives for the method specification.The second part can be subdivided again into components, so-calledhops. In the above file name, there are two hops,@file{rsh@value{postfixmultihop}out@@gate} and@file{telnet@value{postfixmultihop}kai@@real.host}.Each hop can @emph{again} be subdivided into (three) components, the@dfn{hop method}, the @dfn{user name} and the @dfn{host name}. Themeaning of the second and third component should be clear, and the hopmethod says what program to use to perform that hop.The first hop, @file{rsh@value{postfixmultihop}out@@gate},says to use @command{rsh} to log in as user @code{out} to the host@code{gate}. Starting at that host, the second hop,@file{telnet@value{postfixmultihop}kai@@real.host}, says touse @command{telnet} to log in as user @code{kai} to host@code{real.host}.@xref{Multi-hop Methods}, for a list of possible hop method values.The variable @code{tramp-multi-connection-function-alist} contains thelist of possible hop methods and information on how to execute them,should you want to add your own.@node Filename completion@section Filename completion@cindex filename completionFilename completion works with @value{tramp} for both completing methods,user names and machine names (except multi hop methods) as well as forfiles on remote machines.If you, for example, type @kbd{C-x C-f @value{prefix}t@key{TAB}}, @value{tramp} might give you as result the choice for@example@ifset emacs@value{prefixsinglehop}telnet@value{postfixsinglehop} tmp/@value{prefixsinglehop}toto@value{postfix}@end ifset@ifset xemacs@value{prefixsinglehop}telnet@value{postfixsinglehop} @value{prefixsinglehop}toto@value{postfix}@end ifset@end example@samp{@value{prefixsinglehop}telnet@value{postfixsinglehop}}is a possible completion for the respective method,@ifset emacs@samp{tmp/} stands for the directory @file{/tmp} on your localmachine,@end ifsetand @samp{@value{prefixsinglehop}toto@value{postfix}}might be a host @value{tramp} has detected in your @file{~/.ssh/known_hosts}file (given you're using default method @option{ssh}).If you go on to type @kbd{e @key{TAB}}, the minibuffer is completed to@samp{@value{prefix}telnet@value{postfixsinglehop}}.Next @kbd{@key{TAB}} brings you all machine names @value{tramp} detects inyour @file{/etc/hosts} file, let's say@example@value{prefixsinglehop}telnet@value{postfixsinglehop}127.0.0.1@value{postfix} @value{prefixsinglehop}telnet@value{postfixsinglehop}192.168.0.1@value{postfix}@value{prefixsinglehop}telnet@value{postfixsinglehop}localhost@value{postfix} @value{prefixsinglehop}telnet@value{postfixsinglehop}melancholia.danann.net@value{postfix}@value{prefixsinglehop}telnet@value{postfixsinglehop}melancholia@value{postfix}@end exampleNow you can choose the desired machine, and you can continue tocomplete file names on that machine.As filename completion needs to fetch the listing of files from theremote machine, this feature is sometimes fairly slow. As @value{tramp}does not yet cache the results of directory listing, there is no gainin performance the second time you complete filenames.If the configuration files (@pxref{Customizing Completion}), which@value{tramp} uses for analysis of completion, offer user names, those usernames will be taken into account as well.@node Dired@section Dired@cindex dired@value{tramp} works transparently with dired, enabling you to use this powerfulfile management tool to manage files on any machine you have access toover the Internet.If you need to browse a directory tree, Dired is a better choice, atpresent, than filename completion. Dired has its own cache mechanismand will only fetch the directory listing once.@node Compilation@section Compile remote files@cindex compile@cindex recompile@value{tramp} provides commands for compilation of files on remotemachines. In order to get them loaded, you need to require@file{tramp-util.el}:@lisp(require 'tramp-util)@end lispAfterwards, you can use the commands @code{tramp-compile} and@code{tramp-recompile} instead of @code{compile} and @code{recompile},respectively; @inforef{Compilation, ,@value{emacsdir}}. This does notwork for the @option{ftp} and @option{smb} methods.The corresponding key bindings and menu entries calling these commandsare redefined automatically for buffers associated with remote files.After finishing the compilation, you can use the usual commands like@code{previous-error}, @code{next-error} and @code{first-error} fornavigation in the @file{*Compilation*} buffer.@node Bug Reports@chapter Reporting Bugs and Problems@cindex bug reportsBugs and problems with @value{tramp} are actively worked on by the developmentteam. Feature requests and suggestions are also more than welcome.The @value{tramp} mailing list is a great place to get information on workingwith @value{tramp}, solving problems and general discussion and advice on topicsrelating to the package.The mailing list is at @email{tramp-devel@@gnu.org}. Messages sent tothis address go to all the subscribers. This is @emph{not} the addressto send subscription requests to.Subscribing to the list is performed via@uref{http://lists.gnu.org/mailman/listinfo/tramp-devel/,the @value{tramp} Mail Subscription Page}.To report a bug in @value{tramp}, you should execute @kbd{M-x tramp-bug}. Thiswill automatically generate a buffer with the details of your system and@value{tramp} version.When submitting a bug report, please try to describe in excruciatingdetail the steps required to reproduce the problem, the setup of theremote machine and any special conditions that exist.If you can identify a minimal test case that reproduces the problem,include that with your bug report. This will make it much easier for thedevelopment team to analyze and correct the problem.@node Frequently Asked Questions@chapter Frequently Asked Questions@cindex frequently asked questions@cindex FAQ@itemize @bullet@itemWhere can I get the latest @value{tramp}?@value{tramp} is available under the URL below.@noindent@uref{http://ftp.gnu.org/gnu/tramp/}@noindentThere is also a Savannah project page.@noindent@uref{http://savannah.gnu.org/projects/tramp/}@itemWhich systems does it work on?The package has been used successfully on GNU Emacs 20, GNU Emacs 21and GNU Emacs 22, as well as XEmacs 21. XEmacs 20 is moreproblematic, see the notes in @file{tramp.el}. I don't think anybodyhas really tried it on GNU Emacs 19.The package was intended to work on Unix, and it really expects aUnix-like system on the remote end (except the @option{smb} method),but some people seemed to have some success getting it to work on MSWindows NT/2000/XP @value{emacsname}.There is some informations on @value{tramp} on NT at the following URL;many thanks to Joe Stoy for providing the information:@uref{ftp://ftp.comlab.ox.ac.uk/tmp/Joe.Stoy/}@c The link is broken. I've contacted Tom for clarification. Michael.@ignoreThe above mostly contains patches to old ssh versions; Tom Roche has aWeb page with instructions:@uref{http://www4.ncsu.edu/~tlroche/plinkTramp.html}@end ignore??? Is the XEmacs info correct???? Can somebody provide some information for getting it to work on NTEmacs? I think there was some issue with @command{ssh}?@itemI can't stop @value{ftppackagename} starting with @value{emacsname}@ifset emacs@value{ftppackagename} is loaded from @value{tramp} automatically if yourequire a file by the ftp method. Unfortunately, there are some Lisppackages which make @value{ftppackagename} file name handlers active.You can see it applying @kbd{C-h v file-name-handler-alist}:@examplefile-name-handler-alist's value is(("^/[^/:]*\\'" . ange-ftp-completion-hook-function) ("^/[^/:]*[^/:.]:" . ange-ftp-hook-function) ("^/[^/]*$" . tramp-completion-file-name-handler) ("\\`/[^/:]+:" . tramp-file-name-handler) ("\\`/:" . file-name-non-special))@end examplePlease try to find out which package is responsible for loading@value{ftppackagename}, and raise a bug report.A workaround is to require @value{ftppackagename} before @value{tramp} inyour @file{~/.emacs}, because @value{tramp} cleans up the entries in@code{file-name-handler-alist}:@lisp;; @value{ftppackagename} temporarily required(require 'ange-ftp);; @value{tramp} cleans up @code{file-name-handler-alist}(require 'tramp)@end lisp@end ifset@ifset xemacsNot all the older versions of @value{tramp} supported @value{emacsname}correctly. The first thing to do is to make sure that you have thelatest version of @value{tramp} installed.If you do, please try and find out exactly the conditions required forthe @value{ftppackagename} handlers to fire. If you can, putting abreakpoint on @code{efs-ftp-path} and sending in the stack trace alongwith your bug report would make it easier for the developers to work outwhat is going wrong.@end ifset@itemFile name completion does not work with @value{tramp}When you log in to the remote machine, do you see the output of@command{ls} in color? If so, this may be the cause of your problems.@command{ls} outputs @acronym{ANSI} escape sequences that your terminalemulator interprets to set the colors. These escape sequences willconfuse @value{tramp} however.In your @file{.bashrc}, @file{.profile} or equivalent on the remotemachine you probably have an alias configured that adds the option@option{--color=yes} or @option{--color=auto}.You should remove that alias and ensure that a new login @emph{does not}display the output of @command{ls} in color. If you still cannot usefilename completion, report a bug to the @value{tramp} developers.@itemFile name completion does not work in large directories@value{tramp} uses globbing for some operations. (Globbing means to use theshell to expand wildcards such as `*.c'.) This might create longcommand lines, especially in directories with many files. Some shellschoke on long command lines, or don't cope well with the globbingitself.If you have a large directory on the remote end, you may wish to executea command like @samp{ls -d * ..?* > /dev/null} and see if it hangs.Note that you must first start the right shell, which might be@command{/bin/sh}, @command{ksh} or @command{bash}, depending on whichof those supports tilde expansion.@itemHow can I get notified when @value{tramp} file transfers are complete?The following snippet can be put in your @file{~/.emacs} file. Itmakes @value{emacsname} beep after reading from or writing to theremote host.@lisp(defadvice tramp-handle-write-region (after tramp-write-beep-advice activate) " make tramp beep after writing a file." (interactive) (beep))(defadvice tramp-handle-do-copy-or-rename-file (after tramp-copy-beep-advice activate) " make tramp beep after copying a file." (interactive) (beep))(defadvice tramp-handle-insert-file-contents (after tramp-copy-beep-advice activate) " make tramp beep after copying a file." (interactive) (beep))@end lisp@itemThere's this @file{~/.sh_history} file on the remote host which keepsgrowing and growing. What's that?Sometimes, @value{tramp} starts @command{ksh} on the remote host fortilde expansion. Maybe @command{ksh} saves the history by default.@value{tramp} tries to turn off saving the history, but maybe you haveto help. For example, you could put this in your @file{.kshrc}:@exampleif [ -f $HOME/.sh_history ] ; then /bin/rm $HOME/.sh_historyfiif [ "$@{HISTFILE-unset@}" != "unset" ] ; then unset HISTFILEfiif [ "$@{HISTSIZE-unset@}" != "unset" ] ; then unset HISTSIZEfi@end example@item@value{tramp} doesn't transfer strings with more than 500 characterscorrectlyOn some few systems, the implementation of @code{process-send-string}seems to be broken for longer strings. This case, you shouldcustomize the variable @code{tramp-chunksize} to 500. For adescription how to determine whether this is necessary see thedocumentation of @code{tramp-chunksize}.@end itemize@c For the developer@node Version Control@chapter The inner workings of remote version control@cindex Version ControlUnlike @value{ftppackagename}, @value{tramp} has full shell access to theremote machine. This makes it possible to provide version control forfiles accessed under @value{tramp}.The actual version control binaries must be installed on the remotemachine, accessible in the directories specified in@var{tramp-remote-path}.This transparent integration with the version control systems is one ofthe most valuable features provided by @value{tramp}, but it is far from perfect.Work is ongoing to improve the transparency of the system.@menu* Version Controlled Files:: Determining if a file is under version control.* Remote Commands:: Executing the version control commands on the remote machine.* Changed workfiles:: Detecting if the working file has changed.* Checking out files:: Bringing the workfile out of the repository.* Miscellaneous Version Control:: Things related to Version Control that don't fit elsewhere.@end menu@node Version Controlled Files@section Determining if a file is under version controlThe VC package uses the existence of on-disk revision control masterfiles to determine if a given file is under revision control. These filetests happen on the remote machine through the standard @value{tramp} mechanisms.@node Remote Commands@section Executing the version control commands on the remote machineThere are no hooks provided by VC to allow intercepting of the versioncontrol command execution. The calls occur through the@code{call-process} mechanism, a function that is somewhat moreefficient than the @code{shell-command} function but that does notprovide hooks for remote execution of commands.To work around this, the functions @code{vc-do-command} and@code{vc-simple-command} have been advised to intercept requests foroperations on files accessed via @value{tramp}.In the case of a remote file, the @code{shell-command} interface isused, with some wrapper code, to provide the same functionality on theremote machine as would be seen on the local machine.@node Changed workfiles@section Detecting if the working file has changedAs there is currently no way to get access to the mtime of a file on aremote machine in a portable way, the @code{vc-workfile-unchanged-p}function is advised to call an @value{tramp} specific function for remote files.The @code{tramp-vc-workfile-unchanged-p} function uses the functioning VCdiff functionality to determine if any changes have occurred between theworkfile and the version control master.This requires that a shell command be executed remotely, a process thatis notably heavier-weight than the mtime comparison used for localfiles. Unfortunately, unless a portable solution to the issue is found,this will remain the cost of remote version control.@node Checking out files@section Bringing the workfile out of the repositoryVC will, by default, check for remote files and refuse to act on themwhen checking out files from the repository. To work around thisproblem, the function @code{vc-checkout} knows about @value{tramp} files andallows version control to occur.@node Miscellaneous Version Control@section Things related to Version Control that don't fit elsewhereMinor implementation details, &c.@menu* Remote File Ownership:: How VC determines who owns a workfile.* Back-end Versions:: How VC determines what release your RCS is.@end menu@node Remote File Ownership@subsection How VC determines who owns a workfile@value{emacsname} provides the @code{user-full-name} function toreturn the login name of the current user as well as mapping fromarbitrary user id values back to login names. The VC code uses thisfunctionality to map from the uid of the owner of a workfile to thelogin name in some circumstances.This will not, for obvious reasons, work if the remote system has adifferent set of logins. As such, it is necessary to delegate to theremote machine the job of determining the login name associated with auid.Unfortunately, with the profusion of distributed management systems suchas @code{NIS}, @code{NIS+} and @code{NetInfo}, there is no simple,reliable and portable method for performing this mapping.Thankfully, the only place in the VC code that depends on the mapping ofa uid to a login name is the @code{vc-file-owner} function. This returnsthe login of the owner of the file as a string.This function has been advised to use the output of @command{ls} on theremote machine to determine the login name, delegating the problem ofmapping the uid to the login to the remote system which should know moreabout it than I do.@node Back-end Versions@subsection How VC determines what release your RCS isVC needs to know what release your revision control binaries you arerunning as not all features VC supports are available with olderversions of @command{rcs(1)}, @command{cvs(1)} or @command{sccs(1)}.The default implementation of VC determines this value the first time itis needed and then stores the value globally to avoid the overhead ofexecuting a process and parsing its output each time the information isneeded.Unfortunately, life is not quite so easy when remote version controlcomes into the picture. Each remote machine may have a different versionof the version control tools and, while this is painful, we need toensure that unavailable features are not used remotely.To resolve this issue, @value{tramp} currently takes the sledgehammerapproach of making the release values of the revision control toolslocal to each @value{tramp} buffer, forcing VC to determine these valuesagain each time a new file is visited.This has, quite obviously, some performance implications. Thankfully,most of the common operations performed by VC do not actually requirethat the remote version be known. This makes the problem far lessapparent.Eventually these values will be captured by @value{tramp} on a system bysystem basis and the results cached to improve performance.@node Files directories and localnames@chapter How file names, directories and localnames are mangled and managed.@menu* Localname deconstruction:: Breaking a localname into its components.@end menu@node Localname deconstruction@section Breaking a localname into its components.@value{tramp} file names are somewhat different, obviously, to ordinary filenames. As such, the lisp functions @code{file-name-directory} and@code{file-name-nondirectory} are overridden within the @value{tramp}package.Their replacements are reasonably simplistic in their approach. Theydissect the filename, call the original handler on the localname andthen rebuild the @value{tramp} file name with the result.This allows the platform specific hacks in the original handlers to takeeffect while preserving the @value{tramp} file name information.@node Issues@chapter Debatable Issues and What Was Decided@itemize @bullet@item The uuencode method does not always work.Due to the design of @value{tramp}, the encoding and decoding programsneed to read from stdin and write to stdout. On some systems,@command{uudecode -o -} will read stdin and write the decoded file tostdout, on other systems @command{uudecode -p} does the same thing.But some systems have uudecode implementations which cannot do this atall---it is not possible to call these uudecode implementations withsuitable parameters so that they write to stdout.Of course, this could be circumvented: the @code{begin foo 644} linecould be rewritten to put in some temporary file name, then@command{uudecode} could be called, then the temp file could beprinted and deleted.But I have decided that this is too fragile to reliably work, so on somesystems you'll have to do without the uuencode methods.@item @value{tramp} does not work on XEmacs 20.This is because it requires the macro @code{with-timeout} which does notappear to exist in XEmacs 20. I'm somewhat reluctant to add anemulation macro to @value{tramp}, but if somebody who uses XEmacs 20 stepsforward and wishes to implement and test it, please contact me or themailing list.@item The @value{tramp} filename syntax differs between GNU Emacs and XEmacs.The GNU Emacs maintainers wish to use a unified filename syntax forAnge-FTP and @value{tramp} so that users don't have to learn a newsyntax. It is sufficient to learn some extensions to the old syntax.For the XEmacs maintainers, the problems caused from using a unifiedfilename syntax are greater than the gains. The XEmacs package systemuses EFS for downloading new packages. So, obviously, EFS has to beinstalled from the start. If the filenames were unified, @value{tramp}would have to be installed from the start, too.@ifset xemacs@strong{Note:} If you'ld like to use a similar syntax like@value{ftppackagename}, you need the following settings in your initfile:@lisp(setq tramp-unified-filenames t)(require 'tramp)@end lispThe autoload of the @value{emacsname} @value{tramp} package must bedisabled. This can be achieved by setting file permissions @code{000}to the files @file{.../xemacs-packages/lisp/tramp/auto-autoloads.el*}.In case of unified filenames, all @value{emacsname} download sitesare added to @code{tramp-default-method-alist} with default method@option{ftp} @xref{Default Method}. These settings shouldn't be touchedfor proper working of the @value{emacsname} package system.The syntax for unified filenames is described in the @value{tramp} manualfor @value{emacsothername}.@end ifset@end itemize@node Concept Index@comment node-name, next, previous, up@unnumbered Concept Index@printindex cp@contents@c End of tramp.texi - the TRAMP User Manual@bye@c TODO@c@c * Say something about the .login and .profile files of the remote@c shells.@c * Explain how tramp.el works in principle: open a shell on a remote@c host and then send commands to it.@c * Mention that bookmarks are a cool feature to go along with Tramp.@c * Make terminology "inline" vs "out-of-band" consistent.@c It seems that "external" is also used instead of "out-of-band".@c * M. Albinus@c ** Use `filename' resp. `file name' consistently.@c ** Use `host' resp. `machine' consistently.@c ** Consistent small or capitalized words especially in menues.@ignore arch-tag: f96dd66e-6dd3-4c92-8d77-9c56205ba808@end ignore