dotfiles.2022/_home/dot_sz.shrc.d/23_sudo

10 lines
204 B
Plaintext

#alias sudo="/usr/bin/sudo "
alias _sudo="env sudo "
function sudo() {
local cli="$(command -v "${1}")"
[[ -x "$cli" ]] || cli="${1}"
/usr/bin/sudo --preserve-env=PATH,SHRC_D -- "$cli" "${@:2}"
}