When I try to get the path of a file using ⌘ (Command)+
I, it gives the path in a different way.
I see this only after updating to Yosemite. It is not a text. How do I get it in the format
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
Just select the file itself in Finder and press CmdC or go to Edit » Copy. You can then paste the path directly to a terminal window.
Note that this will escape special characters.
If you want the path in human-readable form, you need to do the following:
Paste the following into the field:
tell application "Finder" set sel to the selection as text set the clipboard to POSIX path of sel end tell
It should look like this:
Save the service under any name you like, e.g. Copy human-readable path.
This is part one. Now, set a keyboard shortcut:
Set a keyboard shortcut for your service
Et voilà, now press that shorcut when you need the path of any selected Finder item.