• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Get HFS Path of POSIX Path?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get HFS Path of POSIX Path?


  • Subject: Re: Get HFS Path of POSIX Path?
  • From: Johnny AppleScript <email@hidden>
  • Date: Fri, 24 Sep 2004 09:00:59 -0600

Title: Re: Get HFS Path of POSIX Path?
Thanks Paul,

I knew there was a way of manipulating the POSIX class, but my SA dictionary. Only shows this:

Class POSIX file: A file object specified with a POSIX (slash)-style pathname.
Properties:
    
POSIX path  'file'  [r/o]  -- the POSIX (slash)-style path of any file or alias object

I simply could not coerce that underlined object in my brain to get the 'POSIX file' method you reminded me of below.

Is there something wrong with my dictionary, or am I just not reading the first line (Class POSIX file:) properly? Note that it is in black text (i.e., it does not appear in green as my app keywords do), which I took to just be a header line, not a command.

Thanks -- (a confused)JA


On 04/09/24 8:21 AM, "Paul Berkowitz" <email@hidden> wrote:

> On 9/24/04 7:06 AM, "Johnny AppleScript" <email@hidden> wrote:
>
>>
>> I tried to search my own archives and samples before asking; isn't there a
>> method, other than a text replacement subroutine, to get the HFS path to an
>> object from its POSIX equivalent?
>>
>> have: "/Users/Library/Folder/Object
>> need: ":volumename:Users:Library:Folder:object"
>> where: Users directory is on a volume other than startup volume
>
> POSIX file "/Users/Library/Folder/Object"
>
>   will compile to
>
> file "Disk:Users:Library:Folder:Object"
>
> (It's in the Standard Additions.) You'll find that in order to use it that
> that 'file' thing doesn't do much and needs instead:
>
> POSIX file "/Users/Library/Folder/Object" as alias
> --> alias "Disk:Users:Library:Folder:Object"
>
> or
>
> POSIX file "/Users/Library/Folder/Object" as Unicode text
> --> "Disk:Users:Library:Folder:Object"
>
>
> (The shorthand you've been using of omitting the startup disk in Mac (colon)
> paths will probably stop working someday.)
>
>>
>> I'm finding some problems with file paths when the UNIX path leads (via
>> symlink or otherwise) to another volume when using text replacement for
>> paths (which works most of the time, otherwise).
>
> This method will work even when the POSIX path starts "/Volumes/" etc.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Get HFS Path of POSIX Path?
      • From: Paul Berkowitz <email@hidden>
    • Re: Get HFS Path of POSIX Path?
      • From: Courtney Schwartz <email@hidden>
    • Re: Get HFS Path of POSIX Path?
      • From: "Steven D.Majewski" <email@hidden>
References: 
 >Re: Get HFS Path of POSIX Path? (From: Paul Berkowitz <email@hidden>)

  • Prev by Date: Re: Get HFS Path of POSIX Path?
  • Next by Date: Re: Picking data from a record
  • Previous by thread: Re: Get HFS Path of POSIX Path?
  • Next by thread: Re: Get HFS Path of POSIX Path?
  • Index(es):
    • Date
    • Thread