Pushd and popd

Pushd and popd

In computing, pushd and popd are commands in various Unix, DOS and Microsoft Windows command line interpreters (shells) such as Bash, cmd.exe, 4DOS/4NT and Windows PowerShell. Both commands are used to work with the command line directory stack.

The pushd command saves the current working directory in memory so it can be returned to at any time, optionally changing to a new directory. The popd command returns to the path at the top of the directory stack.

In Windows PowerShell, pushd is a predefined command alias for the Push-Location Cmdlet and popd is a predefined command alias for the Pop-Location Cmdlet. Both serve basically the same purpose.

yntax

pushd

pushd [path | ..]

Arguments:
*path This command-line argument specifies the directory to make the current directory.

popd

popd

Example

C:Users oot>pushd C:

C:>popd

C:Users oot>

ee also

*List of DOS commands
*List of Unix programs

References

* [http://technet.microsoft.com/en-us/library/bb490978.aspx Microsoft TechNet Pushd article]
* [http://technet.microsoft.com/en-us/library/bb490969.aspx Microsoft TechNet Popd article]
* [http://ftp.gnu.org/old-gnu/Manuals/bash-2.05a/html_node/bashref_73.html Bash Reference Manual: Directory Stack Builtins]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем сделать НИР

Look at other dictionaries:

  • pushd and popd — In computing, pushd and popd are commands in various Unix, DOS and Microsoft Windows command line interpreters (shells) such as Bash, cmd.exe, 4DOS/4NT and Windows PowerShell. Both commands are used to work with the command line directory stack.… …   Wikipedia

  • time and date — In computing, time and date are commands that are used to display and set the current time and date of the operating system. Both commands are available in DOS, OS/2 and Microsoft Windows command line interpreters (shells) such as COMMAND.COM,… …   Wikipedia

  • Batch file — This article is about DOS, OS/2 and Windows scripting. For other types of batch programming, see shell script. Batch file Filename extension .bat .cmd .btm Type of format Scripting Container for Shell scripts In DOS, OS/2, and Microsoft Windows,… …   Wikipedia

  • Command Prompt — For other uses, see Command prompt (disambiguation). CMD redirects here. For other uses, see CMD (disambiguation). Command Prompt A component of Microsoft Windows …   Wikipedia

  • cd (command) — cd, sometimes also available as chdir (change directory), is a command line command to change the current working directory in operating systems such as Unix, DOS, OS/2, AmigaOS (where if a bare path is given, cd is implied), Windows, and Linux.… …   Wikipedia

  • Command Prompt (Windows) — Infobox Windows component name = Command Prompt logo size = 64px caption = Command Prompt in Windows Vista| included with = Windows NT Windows CE OS/2 replaces = COMMAND.COM replaced by = related components = Windows PowerShell Batch filecmd.exe… …   Wikipedia

  • Folder (computing) — Screenshot of a Windows command prompt window showing filenames in a directory In computing, a folder, directory,[1] catalog,[citation needed …   Wikipedia

  • Directory (file systems) — In computing, a directory, catalog, folder [ With the introduction of Windows 95, Microsoft started referring to directories as folders. ( [http://www.murach.com/books/csh5/ Murach s C# 2005] , page 34)] or drawer [Name used in AmigaOS… …   Wikipedia

  • Windows PowerShell — Screenshot of a sample PowerShell session …   Wikipedia

  • Windows PowerShell — Screenshot von PowerShell 1.0 Basisdaten Entwickler Microsoft Aktuelle Version 2.0 (26 …   Deutsch Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”