gksu
linux
Frontend for `su`. Allows you to run graphical commands which need root access without having to run an X terminal emulator. Note: This command is deprecated in favor of commands like `pkexec`, and is no longer maintained. See also: `gksudo`.
More info →Options (5)
-u, --userbooleanRun a command as a specific user
Example:
gksu {{[-u|--user]}} {{userid}} {{command}}-k, --preserve-envbooleanRun the command while preserving the current environments
Example:
gksu {{[-u|--user]}} {{userid}} {{[-k|--preserve-env]}} {{command}}-w, --su-modebooleanForce `gksu` to use `su` to run the command
Example:
gksu {{[-u|--user]}} {{userid}} {{[-w|--su-mode]}} {{command}}-S, --sudo-modebooleanForce `gksu` to use `sudo` to run the command
Example:
gksu {{[-u|--user]}} {{userid}} {{[-S|--sudo-mode]}} {{command}}-d, --debugbooleanOutput debug info for the given command
Example:
gksu {{[-u|--user]}} {{userid}} {{[-d|--debug]}} {{command}}Examples (5)
Run the command while preserving the current environments
made by @shridhargupta | data from tldr-pages