Thread (10 messages) flat view 10 messages, 4 authors, 2016-06-15

Re: [PATCH 2/2] show color hints based on state of the git tree

From: Simon Oosthoek <hidden>
Date: 2016-06-15 22:55:02

Possibly related (same subject, not in this thread)

Hi Michael, sorry for the duplicate, forgot to reply-all...

On 10/15/2012 11:13 AM, Michael J Gruber wrote:
...only because you don't know the color coding scheme. It's green
because those changes are saved somewhere (in the index) and would even
survice a branch switch.
But git doesn't exactly let you do this:
I modified some things in git-prompt.sh trying to implement some of what 
we discussed. Then staged the file and tried git checkout HEAD^^ (or any 
branch)

error: Your local changes to the following files would be overwritten by 
checkout:
         contrib/completion/git-prompt.sh
Please, commit your changes or stash them before you can switch branches.
Aborting

So I don't think it's all that strange to mark the branch as not quite 
safe to change. The idea (or at least my idea) behind these hints is 
that it reminds me to do stuff that prevents these "Aborts". I think 
that that is a useful feature for any user of git.

In this light, would you accept yellow in the branch color to indicate 
uncommitted staged changes?

Cheers

Simon
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help