Saturday, June 24, 2017

#1 2005-10-12 03:01:53 pm

From: MalasaƱa, Madrid
Registered: 2002-11-20
Posts: 2014

How can I convert a Unix path to a Mac OS X path, and the other way?

You can do so using "POSIX file" and "POSIX path", which can be found in the "Standard Additions" Scripting Addition.


set theUnixPath to "/Users/Shared/"
(POSIX file theUnixPath) as string
--> "Macintosh HD:Users:Shared:"

set theMacOSXPath to "Macintosh HD:Users:Shared:"
POSIX path of theMacOSXPath
--> "/Users/Shared/"



Board footer

Powered by FluxBB

[ Generated in 0.033 seconds, 10 queries executed ]

RSS (new topics) RSS (active topics)