Navigating the File System in Bash ๐Ÿง

Exploring the Desktop and Documents Folders ๐Ÿ—‚๏ธ

Let's do the same thing in Bash. From our desktop, we're going to navigate to the Documents folder. The commands we used earlier in PowerShell are exactly the same here in Bash.

Print working directory or PWD again, shows us the current path we are in. Looks good. We're currently in our desktop directory, which you can see from /home/cindy/desktop. To navigate around, we use the CD command, just like with Windows. We can give it an absolute path like this, cd /home/cindy/documents, or we can give it a relative path like this, cd ../documents. In Bash, the Tilde ~ is used to reference our home directory, so cd ~/desktop will take us back to our desktop. ๐Ÿ 

Tab Completion in Bash ๐Ÿ’ป

Guess what, we still have that useful tab completion feature in Bash. The difference between Bash tab complete and Windows tab complete is that if we have multiple options, it won't rotate through the options, but instead will show us all options at once. Like this, we can already start connecting the bridge between Windows and Linux. ๐ŸŒ‰

Last updated