back to top
Saturday, May 11, 2024
HomePC Softwarelearn how to use one of the most useful CMD commands in...

learn how to use one of the most useful CMD commands in Windows

By simply opening a command prompt window in Windows we can start working through the many commands that we have at our disposal. Dir is one of the most important and common, so we are going to show you a good part of its secrets.

At first, the main objective of this important command is quite simple and easy to understand. We have nothing more than run Dir in the command prompt window to list all files and folders in the current directory. In addition, as in many other commands, this command also accepts special arguments to carry out different tasks, as we will see.

Despite the simplicity shown by this order that we execute in the Windows command prompt window, this is a much more powerful command than we might think at first. This is precisely what we want to talk to you about below in order to know the secrets of Dir and be able to get the most out of it.

Most important functions of the Dir command in Windows

There are many variants that Dir offers us using the available parameters proposed by the Microsoft operating system. Below we are going to show you some of the most useful ways of using it with its different parameters and variables.

  • Dir: By simply typing the command itself, a list of the files and folders in the current directory is displayed on the screen.
  • Dir /AD– Shows all directories in the current path.
  • Dir /AR: for read-only files.
  • Dir /AH– Shows hidden files in the path.
  • Dir /AS: shows us the system files.
  • Dir /AI: Used to view those not indexed by content.
  • Dir /B: removes all excess information that will appear on the screen. This way it only shows the name of the folders and files in the current directory, without additional attributes.
  • Dir /D: organizes the results displayed on the screen in two columns to make them more comfortable to understand and read.
  • Dir /L– Displays all file and folder names in lowercase.
  • Dir /OD– Sorts output files and folders by date and time. The oldest content appears first.
  • Dir /OE: We will see the contents shown in the list ordered alphabetically depending on its length.
  • Dir /OG: in this way the command places the folders contained in the current path first.
  • Dir /ON: with this parameter we can sort the list alphabetically based on its name.
  • Dir /OS: so we can sort the files by size, from smallest to largest.
  • Dir /P: If the list is too long, the command will pause so that we can see the contents in a much more comfortable way on the screen.
  • Dir /Q– Displays metadata linked to files and folders along with property details.

These are some of the most important parameters that we can use together with this powerful command, which will allow us get custom lists of files and folders stored on our hard drive.

Mark Tyson
Mark Tyson
Freelance News Writer. Always interested in the way in which technology can change people's lives, and that is why I also advise individuals and companies when it comes to adopting all the advances in Apple devices and services.
RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Fresh