Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I having trouble with an application not prompting for administrator privileges (thank you Blizzard's WOW installer) and I'm looking for an OS X equivalent of Windows' RunAs.

I am familiar with SUDO, but don't want to use it as it is often a pain to drill down to the relevant binary in the application package.

share|improve this question

2 Answers 2

up vote 2 down vote accepted

You can use an application called Pseudo to run any application as root. It's nothing more than a shell for sudo, but will accomplish your goal of not having to dig around in application bundles.

I would not recommend using it in this case, though. Broken program can do far more damage as root than as a normal user, and if the WOW installer isn't doing what it's supposed to when you're not an admin, I wouldn't trust it with root priviliges.

Just run the installer logged in as an admin. If that doesn't help, your problem is somewhere else.

share|improve this answer
    
Blizzard is just lazy and tries to install the whole shebang to the users home directory. I just want it to go into Applications like all other programs. –  James McMahon Aug 6 '09 at 0:19
3  
Then if you run it as root, it will install to root's home directory and no one else will be able to access it. Install as a normal user, then move the application directory to /Applications. –  Sidnicious Aug 6 '09 at 2:11
1  
@SidenySM, you can point the installer at whatever directory, it just needs admin to write to /Applications. –  James McMahon Aug 6 '09 at 20:13
    
I didn't had any such issues with WOW installer, @James. And I installed it to /Applications as default. Wondering what could have really happened in your end... I did download the installer from Blizzard website. –  Cawas May 21 '10 at 0:08
    
@Cawas, the first Mac OsX account is admin by default. The account I run under is pure user, which could account for the behavior. Also it has been about a year since I posted this, so Blizzard could have improved their installer. –  James McMahon Jul 21 '10 at 12:40

This is probably rare enough that it's not worth going to great lengths to make the process elegant, but you can write a very simple Applescript to elevate an app for you. There are lots of ways to approach it, but if you want it to show you a file picker and then prompt for the Administrator password you could use something like:

set filePath to (POSIX path of (choose file))
do shell script "open \"" & filePath & "\"" with administrator privileges

open will figure out how to find the executable in a App bundle. This will also work with other file types, for instance system configuration files.

You could also make this a droplet or a script menu entry that worked on the current Finder selection. If you add the text: password "yourPass" to the end of the second line then you can suppress the authentication prompt, but I certainly wouldn't recommend that.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.