Une petit article en anglais pioché sur ma navigation web et qui nous apprend comment conserver facilement le chemin d’accès à un fichier sous la dernière version d’OSX. Bonne lecture.
Advanced Mac users who need frequent access to a files complete path in OS X may find themselves turning to the drag & drop Terminal trick or performing a variety of other tricks to copy an items path, but with OS X 10.11 and later, there’s a new native Copy Pathname option built directly into the Finder. Just as it sounds, it will copy the complete pathname of a file or folder directly to the clipboard.
Using Copy Item as Pathname in OS X Finder is really easy, here’s all you need to do to copy any items path name directly to the clipboard from anywhere in the file system:
- Navigate to the file or folder you wish to copy the path for
- Right-click (or Control+Click, or a Two-Finger click on trackpads) on the file or folder in the Mac Finder
- While in the right-click menu, hold down the OPTION key to reveal the “Copy (item name) as Pathname” option, it replaces the standard Copy option
- Once selected, the file or folders path is now in the clipboard, ready to be pasted anywhere
The copied pathname is always the complete path, it’s not relative.
As an example, choosing “Copy (file) as Pathname)” in the screen shot example on a file called com.apple.Boot.plist copies in the /Library/Preferences/SystemConfiguration/ folder (where OS X network settings are stored) will copy the following file path into the clipboard, which can then be pasted anywhere as so: