12 |
@c Makefile, so you should edit the top-level Makefile to change |
@c Makefile, so you should edit the top-level Makefile to change |
13 |
@c the version number. |
@c the version number. |
14 |
@macro trampver{} |
@macro trampver{} |
15 |
2.0.29 |
2.0.30 |
16 |
@end macro |
@end macro |
17 |
|
|
18 |
@c Entries for @command{install-info} to use |
@c Entries for @command{install-info} to use |
57 |
@end ifset |
@end ifset |
58 |
|
|
59 |
@c Macros for formatting a filename. |
@c Macros for formatting a filename. |
60 |
@c trampfn is for a full filename, trampfnmhp means method, host, path |
@c trampfn is for a full filename, trampfnmhp means method, host, localname |
61 |
@c were given, and so on. |
@c were given, and so on. |
62 |
@macro trampfn(method, user, host, path) |
@macro trampfn(method, user, host, localname) |
63 |
@value{tramp-prefix}@value{method}@value{user}@@@value{host}@value{tramp-postfix}@value{path} |
@value{tramp-prefix}@value{method}@value{user}@@@value{host}@value{tramp-postfix}@value{localname} |
64 |
@end macro |
@end macro |
65 |
|
|
66 |
@copying |
@copying |
67 |
Copyright @copyright{} 1999, 2000, 2001, 2002, 2003 Free Software |
Copyright @copyright{} 1999, 2000, 2001, 2002, 2003 Free Software |
68 |
Foundation, Inc. |
Foundation, Inc. |
69 |
|
|
70 |
@quotation |
@quotation |
71 |
Permission is granted to copy, distribute and/or modify this document |
Permission is granted to copy, distribute and/or modify this document |
72 |
under the terms of the GNU Free Documentation License, Version 1.1 or |
under the terms of the GNU Free Documentation License, Version 1.1 or |
73 |
any later version published by the Free Software Foundation; with no |
any later version published by the Free Software Foundation; with no |
158 |
|
|
159 |
For the developer: |
For the developer: |
160 |
* Version Control:: The inner workings of remote version control. |
* Version Control:: The inner workings of remote version control. |
161 |
* Files directories and paths:: How file names, directories and paths are mangled and managed. |
* Files directories and localnames:: How file names, directories and localnames are mangled and managed. |
162 |
* Issues:: Debatable Issues and What Was Decided. |
* Issues:: Debatable Issues and What Was Decided. |
163 |
|
|
164 |
@detailmenu |
@detailmenu |
197 |
* Remote File Ownership:: How VC determines who owns a workfile. |
* Remote File Ownership:: How VC determines who owns a workfile. |
198 |
* Back-end Versions:: How VC determines what release your RCS is. |
* Back-end Versions:: How VC determines what release your RCS is. |
199 |
|
|
200 |
How file names, directories and paths are mangled and managed. |
How file names, directories and localnames are mangled and managed. |
201 |
|
|
202 |
* Path deconstruction:: Breaking a path into its components. |
* Localname deconstruction:: Breaking a localname into its components. |
203 |
|
|
204 |
@end detailmenu |
@end detailmenu |
205 |
@end menu |
@end menu |
447 |
|
|
448 |
@itemize @bullet |
@itemize @bullet |
449 |
@item |
@item |
450 |
Choose a directory, say @file{~/@value{emacs-dir}/}. Change into that directory and |
Choose a directory, say @file{~/@value{emacs-dir}/}. Change into that |
451 |
unpack the tarball. This will give you a directory |
directory and unpack the tarball. This will give you a directory |
452 |
@file{~/@value{emacs-dir}/tramp/} which contains subdirectories @file{lisp} for the |
@file{~/@value{emacs-dir}/tramp/} which contains subdirectories |
453 |
Lisp code and @file{texi} for the documentation. |
@file{lisp} for the Lisp code and @file{texi} for the documentation. |
454 |
|
|
455 |
@item |
@item |
456 |
Optionally byte-compile all files in the Lisp directory, |
Optionally byte-compile all files in the Lisp directory, |
457 |
@file{~/@value{emacs-dir}/tramp/lisp/}, by issuing a command like the following from |
@file{~/@value{emacs-dir}/tramp/lisp/}, by issuing a command like the |
458 |
the top level directory @file{~/@value{emacs-dir}/tramp/}: |
following from the top level directory |
459 |
|
@file{~/@value{emacs-dir}/tramp/}: |
460 |
|
|
461 |
@example |
@example |
462 |
make EMACS=@value{emacs-dir} all |
make EMACS=@value{emacs-dir} all |
463 |
@end example |
@end example |
464 |
|
|
465 |
|
If there are missing libraries reported it is likely they are provided |
466 |
|
in the @file{~/@value{emacs-dir}/tramp/contrib/} directory. This |
467 |
|
case, you need to call @command{make} like this: |
468 |
|
|
469 |
|
@example |
470 |
|
make EMACS=@value{emacs-dir} USE_CONTRIB=1 all |
471 |
|
@end example |
472 |
|
|
473 |
@item |
@item |
474 |
NOTE: If you run into problems running the example @command{make} |
NOTE: If you run into problems running the example @command{make} |
475 |
command, don't despair. You can still byte compile the @file{*.el} |
command, don't despair. You can still byte compile the @file{*.el} |
488 |
|
|
489 |
@lisp |
@lisp |
490 |
(add-to-list 'load-path "~/@value{emacs-dir}/tramp/lisp/") |
(add-to-list 'load-path "~/@value{emacs-dir}/tramp/lisp/") |
491 |
|
(add-to-list 'load-path "~/@value{emacs-dir}/tramp/contrib/") |
492 |
(require 'tramp) |
(require 'tramp) |
493 |
@end lisp |
@end lisp |
494 |
|
|
495 |
|
The second @command{add-to-list} must be used only if you've compiled |
496 |
|
with the @command{USE_CONTRIB} parameter. |
497 |
|
|
498 |
@item |
@item |
499 |
To be able to read the Info documentation, create a file |
To be able to read the Info documentation, create a file |
500 |
@file{~/@value{emacs-dir}/tramp/texi/dir} using the |
@file{~/@value{emacs-dir}/tramp/texi/dir} using the |
991 |
far, it is tested towards MS Windows NT, MS Windows 2000, and MS |
far, it is tested towards MS Windows NT, MS Windows 2000, and MS |
992 |
Windows XP. |
Windows XP. |
993 |
|
|
994 |
The first directory in the path must be a share name on the remote |
The first directory in the localname must be a share name on the remote |
995 |
host. Remember, that the @code{$} character in which default shares |
host. Remember, that the @code{$} character in which default shares |
996 |
usually end, must be written @code{$$} due to environment variable |
usually end, must be written @code{$$} due to environment variable |
997 |
substitution in file names. If no share name is given (i.e. remote |
substitution in file names. If no share name is given (i.e. remote |
1039 |
|
|
1040 |
@cindex method multi |
@cindex method multi |
1041 |
@cindex multi method |
@cindex multi method |
1042 |
A multi-hop file name specifies a method, a number of hops, and a path |
A multi-hop file name specifies a method, a number of hops, and a |
1043 |
name on the remote system. The method name is always |
localname (path name on the remote system). The method name is always |
1044 |
@option{multi}. |
@option{multi}. |
1045 |
|
|
1046 |
Each hop consists of a @dfn{hop method} specification, a user name and |
Each hop consists of a @dfn{hop method} specification, a user name and |
1121 |
When you select an appropriate transfer method for your typical usage |
When you select an appropriate transfer method for your typical usage |
1122 |
you should set the variable @var{tramp-default-method} to reflect that |
you should set the variable @var{tramp-default-method} to reflect that |
1123 |
choice. This variable controls which method will be used when a method |
choice. This variable controls which method will be used when a method |
1124 |
is not specified in the @tramp{} file path. For example: |
is not specified in the @tramp{} file name. For example: |
1125 |
|
|
1126 |
@lisp |
@lisp |
1127 |
(setq tramp-default-method "scp") |
(setq tramp-default-method "scp") |
1215 |
|
|
1216 |
@defun tramp-set-completion-function method function-list |
@defun tramp-set-completion-function method function-list |
1217 |
This function sets @var{function-list} as list of completion functions |
This function sets @var{function-list} as list of completion functions |
1218 |
for @var{method}. |
for @var{method}. |
1219 |
|
|
1220 |
Example: |
Example: |
1221 |
@example |
@example |
1500 |
@cindex filename syntax |
@cindex filename syntax |
1501 |
@cindex filename examples |
@cindex filename examples |
1502 |
|
|
1503 |
To access the file @var{path} on the remote machine @var{machine} you |
To access the file @var{localname} on the remote machine @var{machine} you |
1504 |
would specify the filename |
would specify the filename |
1505 |
@file{@value{tramp-prefix}@var{machine}@value{tramp-postfix}@var{path}}. |
@file{@value{tramp-prefix}@var{machine}@value{tramp-postfix}@var{localname}}. |
1506 |
This will connect to @var{machine} and transfer the file using the |
This will connect to @var{machine} and transfer the file using the |
1507 |
default method. @xref{Default Method}. |
default method. @xref{Default Method}. |
1508 |
|
|
1898 |
fi |
fi |
1899 |
@end example |
@end example |
1900 |
|
|
1901 |
|
|
1902 |
|
@item @tramp{} doesn't transfer strings with more than 500 characters |
1903 |
|
correctly |
1904 |
|
|
1905 |
|
On some few systems, the implementation of @code{process-send-string} |
1906 |
|
seems to be broken for longer strings. This case, you should |
1907 |
|
customize the variable @code{tramp-chunksize} to 500. For a |
1908 |
|
description how to determine whether this is necessary see the |
1909 |
|
documentation of @code{tramp-chunksize}. |
1910 |
|
|
1911 |
@end itemize |
@end itemize |
1912 |
|
|
1913 |
|
|
1959 |
|
|
1960 |
In the case of a remote file, the @code{shell-command} interface is |
In the case of a remote file, the @code{shell-command} interface is |
1961 |
used, with some wrapper code, to provide the same functionality on the |
used, with some wrapper code, to provide the same functionality on the |
1962 |
remote machine as would be seen on the local machine. |
remote machine as would be seen on the local machine. |
1963 |
|
|
1964 |
|
|
1965 |
@node Changed workfiles |
@node Changed workfiles |
2057 |
system basis and the results cached to improve performance. |
system basis and the results cached to improve performance. |
2058 |
|
|
2059 |
|
|
2060 |
@node Files directories and paths |
@node Files directories and localnames |
2061 |
@chapter How file names, directories and paths are mangled and managed. |
@chapter How file names, directories and localnames are mangled and managed. |
2062 |
|
|
2063 |
@menu |
@menu |
2064 |
* Path deconstruction:: Breaking a path into its components. |
* Localname deconstruction:: Breaking a localname into its components. |
2065 |
@end menu |
@end menu |
2066 |
|
|
2067 |
|
|
2068 |
@node Path deconstruction |
@node Localname deconstruction |
2069 |
@section Breaking a path into its components. |
@section Breaking a localname into its components. |
2070 |
|
|
2071 |
@tramp{} filenames are somewhat different, obviously, to ordinary path |
@tramp{} file names are somewhat different, obviously, to ordinary file |
2072 |
names. As such, the lisp functions @code{file-name-directory} and |
names. As such, the lisp functions @code{file-name-directory} and |
2073 |
@code{file-name-nondirectory} are overridden within the @tramp{} package. |
@code{file-name-nondirectory} are overridden within the @tramp{} |
2074 |
|
package. |
2075 |
|
|
2076 |
Their replacements are reasonably simplistic in their approach. They |
Their replacements are reasonably simplistic in their approach. They |
2077 |
dissect the filename, call the original handler on the remote path and |
dissect the filename, call the original handler on the localname and |
2078 |
then rebuild the @tramp{} path with the result. |
then rebuild the @tramp{} file name with the result. |
2079 |
|
|
2080 |
This allows the platform specific hacks in the original handlers to take |
This allows the platform specific hacks in the original handlers to take |
2081 |
effect while preserving the @tramp{} path information. |
effect while preserving the @tramp{} file name information. |
2082 |
|
|
2083 |
|
|
2084 |
@node Issues |
@node Issues |