14.12 Marking Your Place with a Shell VariableThe following alias will store the current directory name in a variable:
alias mark 'set \!:1=$cwd' so as to use a feature of the C shell:
%
One need not even type
(I generally use
pushd
and
popd
(
14.6
)
to store directory names;
mark
is
more useful with commands that need to look in two different paths,
and there
[In
bash
, you can do this by setting the
cdable_vars
variable.
(Put - in comp.unix.wizards on Usenet, 14 February 1987 |
|