Skip to content

Instantly share code, notes, and snippets.

@schallis
Created May 15, 2012 22:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save schallis/2705714 to your computer and use it in GitHub Desktop.
Save schallis/2705714 to your computer and use it in GitHub Desktop.
Check keychain status
export RED="\033[0;31m"
export NO_COLOUR="\033[0m"
function check_keys() {
ssh-add -l >/dev/null
if [ $? -gt 0 ]
then
echo -en $RED
echo "You should add your key to the keychain"
echo -en $NO_COLOUR
else
echo "Keys all good!"
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment