Commit 0e5a9b16 authored by Éamonn Murray's avatar Éamonn Murray

Add detail on paths

parent 05d6b00c
......@@ -94,6 +94,25 @@ so you should see several automatically generated directories. Note `ls` has
been set to use colour highlighting for you by default, so different types of
files are shown in different colours.
You can list the contents of any directory by name. For example:
- `ls /usr/share/` will list the contents of that directory. Here we have
provided the full (absolute) path, since we started with /.
- The filesystem hierarchy always has `/` as the very top level directory
for a linux system.
- If we specify a path to a directory, beginning with `/` it means we are
giving its absolute path from the top level directory down to its
location.
- Your home directory is `/home/username/` where username is whatever you
typed as your username to log in. ` ~` is a shortened way to write this:
`~` also refers to your home directory.
- `ls Documents` will list the contents of the `Documents` directory below the
current directory _if it exists_. This is the same as typing
`ls ./Documents` as will be discussed later. Note this directory is empty to
begin with so you won't see any output from this command.
- Here we specify a path without a leading `/`. It means we are referring
to a file or directory relative to your current location.
#### Useful Options
- `ls -lh`. The `-l` option requests a long listing format, giving extra
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment