Navigating Files and Folders
Learn how to navigate files and folders using the CLI.
We'll cover the following...
Navigating directories
The cd
command lets us change directories. It’s the tool for changing our current working directory, or the location on the filesystem. As we’ve already seen, using cd
by itself takes us straight to our home directory:
$ cd
Then, we execute the pwd
command to check our location. We’ll then see a file path displayed:
$ pwd
If you’ve built a website and referenced images or CSS files, or written code to work with files, you’re already familiar with the concept of specifying paths to files.
The home directory is just one part of the filesystem. The filesystem is a hierarchy of files and directories, starting at the root directory, which we represent with the forward-slash character ( ...