Getting a file path in Finder

Every once in a while you need to get the UNIX style path (aka POSIX) to a file or folder in the Finder. I wrote a little Automator workflow that you can put in your ~/Library/Workflows/Applications/Finder and it will show up in the right click Automator context menu.
There are two versions of the workflow attached to this posting. The difference is mostly so that people can see how to make them either using the Automator components or just using the simple Applescript. The first one Copy Path to Clipboard.workflow uses the Applescript method and the second Copy Path to Clipboard 2.workflow uses a couple of Automator components. I will note that the first one runs faster. If you are only concerned with using it, use the first one.
Here are the Workflows for reference. You can open the files in Automator and see them as well.
Copy Path to Clipboard.workflow

Copy Path to Clipboard 2.workflow

These both are designed for single item selection. You can modify them so they do the right thing if multiple items are selected but that is such a rare case that I haven't had the need to do that.
| Attachment | Size |
|---|---|
| Copy Path to Clipboard.workflow.zip | 41.35 KB |
| Copy Path to Clipboard 2.workflow.zip | 69.54 KB |
| AutomatorScreenSnapz001.png | 18.59 KB |
| AutomatorScreenSnapz002.png | 33.84 KB |


Post new comment