Gksu in 14.04?

Tom H tomh0665 at gmail.com
Wed Aug 6 20:39:37 UTC 2014


On Wed, Aug 6, 2014 at 2:15 PM, Chris <cpollock at embarqmail.com> wrote:
> On Wed, 2014-08-06 at 11:05 -0700, MR ZenWiz wrote:
>> On Wed, Aug 6, 2014 at 10:59 AM, MR ZenWiz <mrzenwiz at gmail.com> wrote:
>>> On Wed, Aug 6, 2014 at 10:10 AM, Tom H <tomh0665 at gmail.com> wrote:
>>>>
>>>> gksu/gksudo is abandonware upstream and pkexec is the replacement.
>>>
>>> Thank you.
>>
>> PS: It would have been really handy to have this listed in the release notes....
>
> Since I'm still new to Ubuntu I'd been using gksudo as advised when I
> first installed it a few weeks ago. Tried just now using 'pkexec' and
> got this:
>
> chris at localhost:~$ pkexec nautilus
> error: XDG_RUNTIME_DIR not set in the environment.
>
> (nautilus:4694): Gtk-WARNING **: cannot open display:
>
> What needs to be done to fix this issue?

I should've tried pkexec before posting. :(

I really thought that it was usable as-is. What's the point?!

It works with

pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY XDG_RUNTIME_DIR=/tmp nautilus

from a terminal (but not from alt-f2!).

You could create a "pk" function and put it into your .bashrc or
.aliases so as not to have to type all of this nonsense.




More information about the ubuntu-users mailing list