File system

Relative paths

Relative file paths start at the current directory.

../../chaz

This is the relative path from /ada/data to /chaz

Click or tap a directory to set the current directory, then tap or click another to see the relative path between the two.

There’s no way to just hop across between siblings. You must go up to the parent (with ..) and then down again.

The downside of relative paths is that they are — by definition — sensitive to the context of where they are used. Unlike absolute paths, you need a different relative path to access the same file from different locations within the file structure.

This means you can sometimes break programs that use relative paths if you run them from the wrong directory.

Using the “current directory” ./

You don’t always need to use the dot to indicate “current directory” at the start of a relative path. It’s redundant, because it means “start where I am”, which is what a relative path means anyway. However, it does indicate that you’re deliberately using relative addressing. So some operations on the command line (such as autocomplete, or running an executable file) work best if you use it.