Helper Commands

Now that we’ve covered the basics of navigating your filesystem from the command line, let’s look at some helpful commands that will make using it easier!

clear is used to clear your terminal, which is useful when it’s full of previous commands and outputs. It doesn’t change or undo your previous commands, it just clears them from the view. You can scroll upwards to see them at any time.

tab can be used to autocomplete your command. When you are typing the name of an existing file or directory, you can use tab to finish the rest of the name.

The up and down arrows ( and ) can be used to cycle through your previous commands. will take you up through your most recent commands, and will take you back through to the most recent one.


Experiment with the helper commands! Some things you could try are:

  • When your working directory is home/ccuser/workspace/blog, type cd 2 and then use tab - it should autocomplete upto cd 201. This is because both possible directories (2014 and 2015) start with 201.
  • Use ls to see what contents are in your working directory. Then use cd with the first letter of one of the files or directories and use tab to autocomplete.
  • Use the up and down arrows to cycle through your previous commands.
  • Use clear to clear your previous commands and output from the terminal.
Folder Icon

Sign up to start coding

Already have an account?