Ubuntu – How to run a Desktop graphical application just once under sudo

guisudo

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.

Best Answer

  • 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.