Hamilton LaboratoriesHamilton C shell 2012User guideBuiltin utilities

pushd

Oregon Coast

pushd
Previous | Next

        Push a new Current Directory and Disk onto the Stack

Usage:  pushd [-hs-] [ -c [n] ] [ directory ]

   Go to a new current directory and disk, saving the old values
   on the directory stack.  If no operands are given, swap the
   top two elements of the stack.  If the path you specify is just
   3 or more dots, pushd will interpret that specially.  Just as ".."
   means go up one level, "..." means up 2 levels, "...." means
   up 3 levels, etc.  If the directory isn't found, the CDPATH is
   searched.

   (See also the cd, dirs, popd and rotd commands.)

Options:

   -c   Copy an item already on the stack onto the top.  This form takes
        an optional parameter n which specifies the integer item number,
        counting from 0 at the top.  Default is n == 0.
   -s   Silent.  Don't print the resulting directory stack.
   -h   Help.  (This screen.)
   --   End of options.

(The slash, "/", may be used instead of a minus to introduce
options.  To specify a different set of characters to introduce
options, use the SWITCHCHARS environmental variable.)

Previous | Next