Jeff,
to run commands with admin rights without password, you can do it the unix
way. Run "sudo visudo" and add something like this:
steen ALL=(ALL) NOPASSWD: /usr/bin/du
then from ruby you can run the command without needing a password:
steen$ macirb
irb(main):001:0> spawn 'sudo du -s -m /User
Thank you Mario, the sudo Hey Jeff,
>
> While this is probably not the MacRuby way, this is the Linux Ruby way, and
> should translate over well to Mac OS X. To have your script run as Root, you
> simply do the following:
>
> if Process::UID.euid != 0 || Process::UID.rid != 0
> # Prompt for
Hey Jeff,
While this is probably not the MacRuby way, this is the Linux Ruby way, and
should translate over well to Mac OS X. To have your script run as Root,
you simply do the following:
if Process::UID.euid != 0 || Process::UID.rid != 0
# Prompt for Password here with a Custom GUI
`sudo #{
Hey all, I'm desperately hoping for some help here...
I'm a System Admin for a School District with thousands of Macs. In the past I
developed an AppleScript Studio application that our technicians used to backup
and restore user accounts when we do system migrations and image updates
(basical