OLDPWD

OLDPWD ( OLDP RINT W¯¯ 工作會有 d irectory)所包含的最後 cd 命令之前目錄:

~> $ cd directory
directory> $ echo $OLDPWD
/home/user