« Back to Index

[Bash Print All Alias’]

View original Gist on GitHub

Tags: #bash #alias #list

Bash Print All Alias.sh

bold=$(tput bold)
normal=$(tput sgr0)

# list out all custom defined alias'
alias list='cat ~/.bashrc | grep "^alias" | gsed -En "s/alias (\w+)=(.+)/${bold}\1\n  ${normal}\2\n/p"'