Command: dirs

  DIRS displays the contents of the directory stack.

Syntax:

  DIRS [/?]

Options:

  /?  Shows the help.

Comments:

  DIRS displays the content of the directory stack which is filled up
  by PUSHD and emptied by POPD.
  DIRS is stored in the context segment (directory stack) of
  command.com, for more information see: COMMAND /E:nnn and MEMORY.
  DIRS is a command internal to command.com and needs no other file
  in order to work.

Examples:

  this command            changes the current directory to / shows:
  ============            =========================================
  cd c:\FREEDOS\BIN       c:\FREEDOS\BIN
  pushd c:\GAMES          c:\GAMES        (and stores c:\FREEDOS\BIN)
  pushd c:\UTILS          c:\UTILS        (and stores c:\GAMES)
  pushd c:\packages       c:\packages     (and stores c:\UTILS)
  dirs                    shows the directories stored by pushd:
                            0001=c:\FREEDOS\BIN
                            0002=c:\GAMES
                            0003=c:\UTILS
  popd                    c:\UTILS        (and removes c:\UTILS (0003)
                                          from directory stack)
  popd                    c:\GAMES        (and removes c:\GAMES (0002)
                                          from directory stack)
  popd                    c:\FREEDOS\BIN  (and removes c:\FREEDOS\BIN
                                          (0001) from directory stack)
  popd                    shows the message: "Directory stack empty"

See also:

  cd/chdir
  cdd
  command.com/freecom
  memory
  pushd
  popd

  Copyright © 2004 Robert Platt, updated 2011 and 2022 by W. Spiegl.

  This file is derived from the FreeDOS Spec Command HOWTO.
  See the file H2Cpying for copying conditions.