@c -*-texinfo-*-

@c Copyright (C) 2021-2023 Free Software Foundation, Inc.
@c See file doclicense.texi for copying conditions.

@include trampver.texi

@node ELPA Installation
@ifplaintext
@unnumbered Installing @value{tramp} via GNU ELPA
@end ifplaintext
@ifnotplaintext
@section Installing @value{tramp} via GNU ELPA
@end ifnotplaintext
@cindex installation
@cindex GNU ELPA

@ifplaintext
@ifclear elpainclude
@value{tramp} stands for ``Transparent Remote (file) Access, Multiple
Protocol''.  This package provides remote file editing, similar to
Ange-FTP.

The difference is that Ange-FTP uses FTP to transfer files between the
local and the remote host, whereas @value{tramp} uses a combination of
@option{rsh} and @option{rcp} or other work-alike programs, such as
@option{ssh}/@option{scp}.

A remote file name has always the syntax

@example
@trampfn{method,user%domain@@host#port,/path/to/file}
@end example

Most of the parts are optional, read the manual
@uref{@value{trampurl}} for details.
@end ifclear
@end ifplaintext

@value{tramp} must be compiled for the Emacs version you are running.
If you experience compatibility error messages for the @value{tramp}
package, or if you use another major Emacs version than the version
@value{tramp} has been installed with, you must recompile the package:

@itemize @bullet
@item
Remove all byte-compiled @value{tramp} files

@example
$ rm -f ~/.emacs.d/elpa/tramp-@value{trampver}/tramp*.elc
@end example

@item
Start Emacs with @value{tramp}'s source files

@example
$ emacs -L ~/.emacs.d/elpa/tramp-@value{trampver} -l tramp
@end example

This should not give you the error.

@item
Recompile the @value{tramp} package @strong{with this running Emacs
instance}

@example
M-x tramp-recompile-elpa
@end example

Afterwards, you must restart Emacs.
@end itemize