Skip to content

Instantly share code, notes, and snippets.

View diezguerra's full-sized avatar

Saúl diezguerra

View GitHub Profile
# Snippet setting git branch and git dirty helper
# Commit at the end kept from original snippet, I added the rev-parse stuff and the proper redirection.
set fish_git_dirty_color red
set fish_git_clean_color brown
function parse_git_dirty
if test (git status 2> /dev/null ^&1 | tail -n1) != "nothing to commit (working directory clean)"
echo (set_color $fish_git_dirty_color)
else