This file contains hidden or 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
git_color() { | |
local git_status="$(git status 2> /dev/null)" | |
local output_styles="" | |
if [[ $git_status =~ "nothing to commit, working tree clean" ]]; then | |
# red | |
output_styles="9" | |
elif [[ $git_status =~ "nothing added to commit but untracked files present" ]]; then | |
# yellow | |
output_styles="11" |