Skip to content

Instantly share code, notes, and snippets.

@loranbriggs
Created August 3, 2016 19:54
Show Gist options
  • Save loranbriggs/5170d416f80b7ab45383ba86fd215cbb to your computer and use it in GitHub Desktop.
Save loranbriggs/5170d416f80b7ab45383ba86fd215cbb to your computer and use it in GitHub Desktop.
mkalias, a funtion to add to bashrc to create aliases from the command line
function mkalias () {
if [[ $1 && $2 ]]
then
echo -e "alias $1=\'$2\'" >> ~/.bash_aliases
alias $1=$2
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment