104 |
@cindex environment variables in file names |
@cindex environment variables in file names |
105 |
@cindex expansion of environment variables |
@cindex expansion of environment variables |
106 |
@cindex @code{$} in file names |
@cindex @code{$} in file names |
107 |
@anchor{File Names with $} |
@anchor{File Names with $}@samp{$} in a file name is used to |
108 |
@samp{$} in a file name is used to substitute environment variables. |
substitute an environment variable. The environment variable name |
109 |
For example, if you have used the shell command @command{export |
consists of all the alphanumeric characters after the @samp{$}; |
110 |
|
alternatively, it can be enclosed in braces after the @samp{$}. For |
111 |
|
example, if you have used the shell command @command{export |
112 |
FOO=rms/hacks} to set up an environment variable named @env{FOO}, then |
FOO=rms/hacks} to set up an environment variable named @env{FOO}, then |
113 |
you can use @file{/u/$FOO/test.c} or @file{/u/$@{FOO@}/test.c} as an |
you can use @file{/u/$FOO/test.c} or @file{/u/$@{FOO@}/test.c} as an |
114 |
abbreviation for @file{/u/rms/hacks/test.c}. The environment variable |
abbreviation for @file{/u/rms/hacks/test.c}. If the environment |
115 |
name consists of all the alphanumeric characters after the @samp{$}; |
variable is not defined, no substitution occurs: @file{/u/$notdefined} |
116 |
alternatively, it may be enclosed in braces after the @samp{$}. Note |
stands for itself (assuming the environment variable @env{notdefined} |
117 |
that shell commands to set environment variables affect Emacs only if |
is not defined). |
118 |
done before Emacs is started. |
|
119 |
|
Note that shell commands to set environment variables affect Emacs |
120 |
|
only when done before Emacs is started. |
121 |
|
|
122 |
@cindex home directory shorthand |
@cindex home directory shorthand |
123 |
You can use the @file{~/} in a file name to mean your home directory, |
You can use the @file{~/} in a file name to mean your home directory, |
127 |
value of the environment variable @code{HOME}; see @ref{General |
value of the environment variable @code{HOME}; see @ref{General |
128 |
Variables}.) |
Variables}.) |
129 |
|
|
130 |
To access a file with @samp{$} in its name, type @samp{$$}. This pair |
To access a file with @samp{$} in its name, if the @samp{$} causes |
131 |
is converted to a single @samp{$} at the same time as variable |
expansion, type @samp{$$}. This pair is converted to a single |
132 |
substitution is performed for a single @samp{$}. Alternatively, quote the |
@samp{$} at the same time as variable substitution is performed for a |
133 |
whole file name with @samp{/:} (@pxref{Quoted File Names}). File names |
single @samp{$}. Alternatively, quote the whole file name with |
134 |
which begin with a literal @samp{~} should also be quoted with @samp{/:}. |
@samp{/:} (@pxref{Quoted File Names}). File names which begin with a |
135 |
|
literal @samp{~} should also be quoted with @samp{/:}. |
136 |
|
|
137 |
@findex substitute-in-file-name |
@findex substitute-in-file-name |
138 |
The Lisp function that performs the substitution is called |
The Lisp function that performs the substitution is called |
950 |
|
|
951 |
@cindex auto-save for remote files |
@cindex auto-save for remote files |
952 |
@vindex auto-save-file-name-transforms |
@vindex auto-save-file-name-transforms |
953 |
The variable @code{auto-save-file-name-transforms} allows a |
The variable @code{auto-save-file-name-transforms} allows a degree |
954 |
degree of control over the auto-save file name. The default value is |
of control over the auto-save file name. It lets you specify a series |
955 |
set up to put the auto-save files for remote files |
of regular expressions and replacements to transform the auto save |
956 |
(@pxref{Remote Files}) into the temporary file directory on the local |
file name. The default value puts the auto-save files for remote |
957 |
machine. |
files (@pxref{Remote Files}) into the temporary file directory on the |
958 |
|
local machine. |
959 |
|
|
960 |
When you delete a substantial part of the text in a large buffer, auto |
When you delete a substantial part of the text in a large buffer, auto |
961 |
save turns off temporarily in that buffer. This is because if you |
save turns off temporarily in that buffer. This is because if you |
2645 |
pick up any recent changes from the repository first, using @kbd{C-x v m |
pick up any recent changes from the repository first, using @kbd{C-x v m |
2646 |
@key{RET}}, @pxref{Merging}). |
@key{RET}}, @pxref{Merging}). |
2647 |
|
|
2648 |
|
@vindex vc-cvs-global-switches |
2649 |
|
The variable @code{vc-cvs-global-switches} should be a string |
2650 |
|
specifyng switches to pass to CVS for all CVS operations. |
2651 |
|
|
2652 |
When @code{vc-cvs-stay-local} is @code{t}, VC also makes local |
When @code{vc-cvs-stay-local} is @code{t}, VC also makes local |
2653 |
version backups, so that simple diff and revert operations are |
version backups, so that simple diff and revert operations are |
2654 |
completely local (@pxref{Version Backups}). |
completely local (@pxref{Version Backups}). |
2712 |
|
|
2713 |
@vindex list-directory-brief-switches |
@vindex list-directory-brief-switches |
2714 |
@vindex list-directory-verbose-switches |
@vindex list-directory-verbose-switches |
2715 |
The text of a directory listing is obtained by running @code{ls} in an |
The text of a directory listing is mostly obtained by running |
2716 |
inferior process. Two Emacs variables control the switches passed to |
@code{ls} in an inferior process. Two Emacs variables control the |
2717 |
@code{ls}: @code{list-directory-brief-switches} is a string giving the |
switches passed to @code{ls}: @code{list-directory-brief-switches} is |
2718 |
switches to use in brief listings (@code{"-CF"} by default), and |
a string giving the switches to use in brief listings (@code{"-CF"} by |
2719 |
@code{list-directory-verbose-switches} is a string giving the switches to |
default), and @code{list-directory-verbose-switches} is a string |
2720 |
use in a verbose listing (@code{"-l"} by default). |
giving the switches to use in a verbose listing (@code{"-l"} by |
2721 |
|
default). |
2722 |
|
|
2723 |
|
@vindex directory-free-space-program |
2724 |
|
@vindex directory-free-space-args |
2725 |
|
Emacs adds information about the amount of free space on the disk |
2726 |
|
that contains the directory. To do this, it runs the program |
2727 |
|
specified by @code{directory-free-space-program} with arguments |
2728 |
|
@code{directory-free-space-args}. |
2729 |
|
|
2730 |
@node Comparing Files |
@node Comparing Files |
2731 |
@section Comparing Files |
@section Comparing Files |