Created
October 28, 2017 20:42
-
-
Save mikermcneil/aad04147f9c39eaa3d4c6fbcf50b6dd4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echoSinceTagInfo() | |
{ | |
if git describe --abbrev=0 --tags 1>/dev/null 2>/dev/null; | |
then | |
local LAST_TAG=`git describe --abbrev=0 --tags`; | |
local CHANGED_SINCE_LAST_TAG=`git diff ${LAST_TAG} --shortstat`; | |
if [ -z "${CHANGED_SINCE_LAST_TAG}" ] | |
then | |
echo "Tagged as ${LAST_TAG}" | |
return | |
fi | |
echo -e "Has untagged code changes since ${LAST_TAG}" | |
else | |
echo "No tags yet"; | |
fi | |
} | |
alias gls='clear && echo "-• `pwd`" && echo && ls -G && echo && git branch && echo && echoSinceTagInfo && echo && git status && echo' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
So then:
Yields: