Linuxlab

Chapter 3

The command line: first contact

Updated July 3, 2026

The prompt tells you who you are and where you are:

student@host:~$

On the left, your username and the machine name; after the colon, the current directory (~ is your home directory); at the end, $. A command has three parts: the name, options, arguments.

$ ls -l /etc

Here ls is the command, -l is an option (it changes behavior, printing a detailed list), /etc is the argument (what to work on). Options usually start with a dash.

A few commands to settle in:

$ pwd            # where am I now
$ date           # current date and time
$ echo hello     # prints what you pass it
$ whoami         # who am I

You do not retype everything ea

Free with account

Read the rest with a free account

This chapter is free once you sign in. Create an account to keep reading.

Create a free account

Already have an account? Sign in