pushd |
Stores the name of the current directory and then changes to the specified directory (for use by the popd command earlier in this chapter).
pushd [ path ..]
The directory to make the current directory
Store the current directory (here C:\ ) and change to C:\pub :
pushd C:\pub C:\pub>
See popd to see what you can do with this.
pushd supports relative paths and accepts either a network path or a local drive letter and path. If a network path is specified, a temporary drive letter is created, and pushd then switches the current drive and directory to the specified directory on the temporary drive. popd then deletes the temporary drive letter when it is used.
popd