All courses

Understanding the Linux terminal

Learn how to use the shell, execute commands, and understand command syntax.

Linux Fundamentals 5 min

Understanding the Linux Terminal

The terminal is a text-based interface used to interact with Linux.

A command commonly follows this structure:

command [options] [arguments]

Example:

ls -l /home

Here:

  • "ls" is the command.
  • "-l" is an option.
  • "/home" is the argument.

Essential commands

pwd
whoami
date
clear
history

"pwd" displays your current directory.

"history" displays previously executed commands.

Command help

ls --help
man ls

Use "man" to read a command's manual.

Press "q" to exit most manual pages.

Practical exercise

  1. Open your terminal.
  2. Run "pwd".
  3. Run "history".
  4. Open the manual for "mkdir".
  5. Find the option that creates parent directories.

Knowledge check

  1. What is a command option?
  2. How do you access a command's manual?
  3. Which command displays your current location?