Dir (command)
In computing, dir
(directory) is a command used for file and directory listing, specifically in the command line interface (CLI) of these operating systems: RT-11, CP/M, VMS, DOS, OS/2, Singularity, and Microsoft Windows. It is analogous to the Unix ls
command.
Because it is the primary means of displaying the files and directories on disk or other storage medium within a command window, the dir command is one of the most basic commands employed by users of the command line interface to MS-DOS and subsequent versions of Microsoft Windows.
The dir
command has existed as a DOS command since the initial release of MS-DOS. It is built into the DOS command shell, and is not provided as a separate standalone program.
In DOS and Microsoft Windows, dir checks for switches in the %dircmd% environment variable.
In Windows PowerShell, dir is a predefined command alias for the Get-ChildItem
Cmdlet which basically serves the same purpose.
Read more about Dir (command): Sample Usage