Skip to content

Instantly share code, notes, and snippets.

@ghassanmas
Created August 22, 2022 11:15
Show Gist options
  • Save ghassanmas/6f28efbc93687b8f3e28516d5d9d5f71 to your computer and use it in GitHub Desktop.
Save ghassanmas/6f28efbc93687b8f3e28516d5d9d5f71 to your computer and use it in GitHub Desktop.
addalias(){
name=$1
shift;
echo 'alias '"$name"'="'"$@"'"' >> ~/.bashrc && source ~/.bashrc
echo 'Added command name '"$name"' to do '"$@"''
}
grepz(){
history | grep "$@"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment