• 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: Path To blessed items (OSX and OS9): Odd or Normal?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Path To blessed items (OSX and OS9): Odd or Normal?


  • Subject: Re: Path To blessed items (OSX and OS9): Odd or Normal?
  • From: Rob Jorgensen <email@hidden>
  • Date: Sat, 21 Jun 2003 08:59:24 -0400

At 5:28 PM -0700 6/20/03, Paul Berkowitz wrote:
On 6/19/03 5:11 PM, "Gary Lists" <email@hidden> wrote:

The scripts basically loop through a list of 4-char codes, return the 'path
to' information as a string, and then present a list to the user showing the
code and the path...a choose from list.

It came to my attention that when I would run either of the scripts, for
every code processed for which there was _not_ a pre-existing folder, the
simple execution of the 'path to' command created one.

I was a bit shocked that I hadn't noticed this before, and so I contacted
Rob to see how his newer (and much more organized) version was handling the
similar case in OSX. He did some testing and...

Astonishingly (to us), the same thing happens.


Execute the command

path to "xxxx" -- where xxxx is an OS-valid 4-char folder code

If the folder equivalent did not already exist, then a folder is created at
its default location. If a user does not have 'Apple Extras' or 'Users' and
then they see them sitting there when the script finishes, it is a bit
disconcerting ... and more than rude! ;)

The same behavior occurs with

path to "usrs" as string

"" & (path to "usrs" as string)


We are not saying this is not the proper (um...well known?) behavior, though
it does seem unexpected. We do, however, need to deal with it in our
respective scripts.

It's the proper, known behavior, and is expected by everyone who knows the
'path to' command. It's also desirable in most contexts.

You found an interesting divergence between OS 9 an OS X when moving to the
trash. If it's of any interest, in OS X you could expunge a newly-created
empty folder completely via 'do shell script "rmdir " & quoted form of POSIX
path of folderPath' and in OS 9 via Jon's Commands' fileDelete.

I consider this divergence a bug but since I'm apparently one who doesn't know the "path to" command, I likely don't have enough clout or intelligence to declare that it's a bug. Does Apple maintain a divergence tracker so that morons can report such things and feel like they are doing something good for the Mac/scripting community? :P

--

Rob Jorgensen
Ohio, USA
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Path To blessed items (OSX and OS9): Odd or Normal? (From: Paul Berkowitz <email@hidden>)

  • Prev by Date: Re: Applescript or ASS app as protocol helper?
  • Next by Date: Re: Path To blessed items (OSX and OS9): Odd or Normal?
  • Previous by thread: Re: Path To blessed items (OSX and OS9): Odd or Normal?
  • Next by thread: Path To blessed items (OSX and OS9): Odd or Normal?
  • Index(es):
    • Date
    • Thread