Skip to content

Instantly share code, notes, and snippets.

@colematt
Last active February 12, 2020 18:25
Show Gist options
  • Save colematt/a6c386809866a21bd671fa4ea6b0d54a to your computer and use it in GitHub Desktop.
Save colematt/a6c386809866a21bd671fa4ea6b0d54a to your computer and use it in GitHub Desktop.
Lazy commands for the Bash shell.

Re-run the last command with root privilege.

alias please='sudo $(history -p !!)'

Re-run the last command saying yes to all interactive questions.

alias really='yes | $(history -p !!)'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment