7

For example, I'm trying to run Archive Manager from Ubuntu Desktop (10.04) under sudo otherwise it won't let me extract a Software Development Kit into /usr/local

Update: I don't want sudo to be a permanent change to launching the application; only to run it under sudo when I choose, until it's quit.

3 Answers 3

8

You can run the software from the command-line/terminal with gksudo prefixed to the command, which will present the prompt for your sudoer's password prior to launching.

gksudo file-roller

Though you mentioned you do not want to make this a permanent change - you could add a new Menu item into something like Applications -> System Tools via alacarte (System -> Preferences -> Main Menu) The command for which could be gksudo file-roller creating both a regular Archive Manager launcher and a "root" Archive Manager launcher - for convenience.

2
  • That's beautiful with the gksudo GUI prompt version. Also I like the idea of creating a second set of menu commands for gksudo'd items. Thanks!
    – John K
    Sep 13, 2010 at 5:25
  • Alternatively you can use the alt+f2 dialog and enter gksudo file-roller
    – TJ L
    Sep 14, 2010 at 19:26
2

Check out the package nautilus-gksu. After installing and restarting your session (or just nautilus) you'll be able to right-click on any file/folder and select "Open as administrator" and be prompted for your password. Works well for opening root nautilus windows, root archive managers, root text editors... you get the idea.

0

I've added a Nautilus script that allows me to - from nautilus - open the current folder as root. That way, I could open the current folder as root, right-click and extract the archive using Archive manager and then move the files to /usr/local. When done, I just close the root-nautilus; no permanent change is done, and no need for the command-line.

/N

2

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .