Skip to content

Instantly share code, notes, and snippets.

@sean-kang
Last active December 15, 2015 12:28
Show Gist options
  • Select an option

  • Save sean-kang/5260228 to your computer and use it in GitHub Desktop.

Select an option

Save sean-kang/5260228 to your computer and use it in GitHub Desktop.
Overrides sudo command to pass PATH to sudo. I implemented this since alias didn't work as intended in bash scripts.
function sudo() {
/usr/bin/sudo env PATH=${PATH} "$@"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment