Skip to content

Instantly share code, notes, and snippets.

@JuenTingShie
Last active October 29, 2021 05:41
Show Gist options
  • Save JuenTingShie/96285b88ba2a6646ed230a1c5d411b77 to your computer and use it in GitHub Desktop.
Save JuenTingShie/96285b88ba2a6646ed230a1c5d411b77 to your computer and use it in GitHub Desktop.
cheatsheet in bash
# This simple function is to get cheatsheet from http://cht.sh/
# Nothing complex else!
# install:
# Put into your .bashrc
# usage:
# how {language}/{word1}+{word2}
function how () {
if [ $# -eq 0 ]; then
curl cht.sh/;
else
echo -e "Search for: \033[4;31m$@\033[0m";
curl cht.sh/$@;
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment