dotfiles icon indicating copy to clipboard operation
dotfiles copied to clipboard

You could also show outstanding commits

Open ferretwithaberet opened this issue 4 years ago • 0 comments

Not a issue, maybe a "feature request", but I modified your .bash_prompt like so:

# Check for unstaged changes.
if ! $(git diff-files --quiet --ignore-submodules --); then
	s+="${red}!";
fi;
# Check for untracked files.
if [ -n "$(git ls-files --others --exclude-standard)" ]; then
	s+="${orange}?";
fi;
# Check for uncommitted changes in the index.
if ! $(git diff --quiet --ignore-submodules --cached); then
	s+="${green}+";
fi;
# Check for outstanding commits
if [ -n "$(git log --quiet --oneline origin/master..HEAD 2>/dev/null)" ]; then
	s+="${cyan}^";
fi;

I am a starter in bash scripting, but damn do I love that cyan ^ when I got unpushed commits.

ferretwithaberet avatar May 06 '20 10:05 ferretwithaberet