You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Terminal: I have two types of folder with the same name but Terminal finds only one

Hi All!


I am relatively new to using Terminal to commit gits. On the screenshot there are two types of folders on my Mac: Favourites and Locations. "Documents" folder is in both. I need to access the Locations' "Documents" and I do so by typing a command in my Terminal:


cd /"Destination folder".


When I type cd /Documents it accesses my Favourites' "Documents" but not the Locations' "Documents".


Here is my complete path: Documents > Dev > (File Name).


P.S. I've also checked my current destination folder by typing ls -la but it doesn't list me the right "Documents" folder. I am pretty sure the solution is straightforward but I cannot make it work :(

MacBook Pro with Touch Bar

Posted on Mar 3, 2020 9:20 AM

Reply

Similar questions

1 reply

Mar 5, 2020 2:57 PM in response to yana230

The Documents in your Favorites is the Documents folder in your ‘home’ folder.

/Users/yana/Documents/


The Documents in your Locations is a disk or partition (volume) named Documents, which would get a path like:

/Volumes/Documents/


Neat trick: Terminal is drag-and-drop aware. You can drag-and-drop a file or folder or disk from Finder to the Terminal window, as a shortcut to enter its path in Terminal:


$ cd <space><drag-and-drop folder><enter>

Terminal: I have two types of folder with the same name but Terminal finds only one

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.