MACSCRPT Archives

July 2009

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Emmett Gray <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Tue, 28 Jul 2009 22:45:08 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (18 lines)
If you add a line

do shell script "" with administrator privileges

you'll get the desired action. This only asks for the password, but 
if you want to actually invoke administrator privileges inside a 
shell script, you would write

do shell script "sudo foo" with administrator privileges

----------------------------------
At 10:00 PM -0400 7/28/09, Walter Ian Kaye wrote:
>
>I notice that installers have a way to pop up an authorization dialog
>for writing to areas of the filesystem outside the user's home folder.
>
>Is there any way to do that from AppleScript, or are our digital hands tied?

ATOM RSS1 RSS2