manpages.info - online man pages   

Mac OS X / Darwin man pages : pwd (1)
pwd (1)

Table of Contents

Name

pwd - return working directory name

Synopsis

pwd [-LP]

Description

pwd writes the absolute pathname of the current working directory to the standard output.

The pwd utility exits 0 on success, and >0 if an error occurs.

The following options are available:

-L
Print the logical path to the current working directory, as defined by the shell in the environment variable PWD.

-P
Print the physical path to the current working directory, with symbolic links in the path resolved. This is the default.

Standards

The pwd utility is expected to be IEEE Std 1003.2 (``POSIX.2'') compatible.

See Also

cd(1) , csh(1) , getcwd(3)

Bugs

In csh(1) the command dirs is always faster (although it can give a different answer in the rare case that the current directory or a containing directory was moved after the shell descended into it).


Table of Contents