That's the perfect next step! To navigate between directories in Linux, you use the cd command, which stands for "change directory."
Here are the most common ways to use it:
1. Move to a Specific Folder
If you know the name of a folder inside your current directory, just type:
cd folder_name
2. Move to your Home Directory
No matter where you are in the system, you can instantly return "home" by typing:
cd ~
(Or simply typing cd without any arguments usually does the same thing!)
3. Move Up One Level
If you are inside a folder and want to go back to the "parent" folder (the one containing your current one), use:
cd ..
4. Move to an Absolute Path
You can jump directly to any location by providing the full address starting from the root (/):
cd /home/labex/project
5. Go Back to your Previous Location
If you just switched directories and want to jump back to exactly where you were before, use:
cd -
Try it now!
Since you are currently in /home/labex/project, try moving to your home directory and then back:
cd ~(Move to home)pwd(Confirm you are in /home/labex)cd project(Move back into the project folder)pwd(Verify you are back!)
Give it a try in your terminal!