xsudo - Forward X11 authentication tokens to programs run under sudo
xsudo sudo-arguments ...
Running X Window programs as a different user with sudo generally doesn't work because the target user can't authenticate with the X11 server.
This program copies your authorisation token into a temporary file readable by the target user. Call it in place of sudo.
In addition, you need to make sure that the DISPLAY and XAUTHORITY environment variables are passed to the program run by sudo. See the env_keep
option in sudoers(5) if you find that this is not the case.
Peter Oliver
See https://github.com/mavit/xsudo/issues.
Copyright 2012, Peter Oliver.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.