In article <20011024200003-r01010800-e58cfee9-0921-0108@localhost>, [EMAIL PROTECTED] (John Gruber) wrote:
> Is there an easy, reliable method to turn a Unix-style path into a > Mac HFS-style path? For example, turning > > /Users/gruber/Documents/foo > > into > > Boot:Users:gruber:Documents:foo > > where "Boot" is the name of my startup disk. > > (Why? Because I want to write a script that executes an AppleScript > using Mac OS X's osascript tool. I need to convert the file > arguments into HFS-style paths, because osascript doesn't take > command line arguments and AppleScript doesn't understand Unix-style > paths.) I know this is old, but I don't get in here much. :-) There's a module on CPAN called Mac::FileSpec::Unixish which may be able to help you; Sean Burke wrote it, and it converts Unix paths to Mac paths. You would need to manually prepend the volume name, in this example, of course. -- Chris Nandor [EMAIL PROTECTED] http://pudge.net/ Open Source Development Network [EMAIL PROTECTED] http://osdn.com/