Linux Directory Commands

Directory Commands

  1. ls– This command ‘lists’ the contents of your present working directory.
  2. pwd- Shows you what your present working directory is.
  3. cd– Lets you change directories.
  4. rm– Removes one or more files.
  5. rmdir– Remove an empty directory.
  6. mkdir– Make a directory.
  7. ps– Provides a list of currently running processes.
  8. cp– Copy a file.
  9. mv– Move a file (this is also used to rename a file, “moving” it from one file name to another.)
  10. grep– The global regular expression print program lets you search through a file or output of another program.
  11. find– Find a file on the filesystem (100% accurate, but not fast).
  12. locate– Find a file on the filesystem from a cached list of files (Fast, but not 100% accurate).
  13. man- Displays the manual for most commands (including ‘man’).
  14. clear- clear the screen
  15. less– view the contents of a file
  16. nano– a simple text editor
  17. sudo– execute a command as another user (default as root)
  18. su– switch user (default to root)
  19. view– Start in read-only mode. You will be protected from writing the files. Can also be done with the “-R” argument.

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.