Linux Tutorial Series

Linux Tutorial Series – 50 – Recap

Here is the video version, if you prefer it:

Here are all of the commands we have learned: 

  • The general command format is: command -options arguments
  • Commands are case sensitive
  • cd directory to change the directory you are located in (current directory)
  • pwd to print the absolute path to the directory you are in
  • man command gives you the man pages of the command
  • Options can be both short (-) and long (--)
  • Use -h or --help to see a quick description of command usage
  • ls command lists directory contents
  • cp src dest copies from source (src) to destination (dest)
  • mv old new renames file with filename old to filename new
  • rm item is used to delete the item; rm -r folder to delete the folder
  • touch filename to create a new file with name filename
  • mkdir dirname to create a new directory with name dirname
  • rmdir dirname to remove a directory with the name dirname (the directory has to be empty)
  • echo message to print out the message
  • cat filename to print out the contents of the filename
  • less filename to page through the contents of the filename
  • head and tail for viewing only the first or the last portion of a file
  • sudo command to execute the command as the superuser
  • su to switch user (without an argument switches to the superuser)
  • grep pattern file for pattern matching in files
  • wc file to count the number of words (and other stuff) in a file – haven’t used it as much

Hope this refreshed your memory!

NewsletterUpdates on interesting things I am doing

Subscribe to my newsletter to keep abreast of the interesting things I'm doing. I will send you the newsletter only when there is something interesting. This means 0% spam, 100% interesting content.

Leave a Reply

Your email address will not be published. Required fields are marked *