What Is Directory Command in Linux?

What Is Directory Command in Linux?
Contents

dir command in Linux is used to list the contents of a directory.

What is the directory in Linux?

Everything on your Linux system is located under the / directory, known as the root directory. You can think of the / directory as being similar to the C: directory on Windows — but this isn’t strictly true, as Linux doesn’t have drive letters.

What are file and directory commands in Linux?

Linux Commands – Working with files and directories

  • pwd. This command displays the present working directory where you are currently in. …
  • ls. This command will list the content of a directory. …
  • ls -la. …
  • mkdir. …
  • mkdir -p. …
  • rmdir. …
  • cd. …
  • cd ..
Sarah Jenkins
Author

Sarah Jenkins

Sarah Jenkins is a veteran tech journalist with over 12 years of experience covering artificial intelligence, mobile innovations, and digital ethics. Her insights have appeared in leading technology publications worldwide.