Alex Rivera | Logout

What does git [master +2 ~1 -0 !] mean?

Asked 2012-08-18T19:07:35.080
18

I'm using the "Github For Windows" shell and was trying to commit something and came across what looks like an error:

C:\Path\Name\ [master +2 ~1 -0 !]> 

What does +2 ~1 -0 ! mean?

NOTE: I fixed the error by modifing every file in the directory and re commiting and pushing, now it's just [master], but I still don't understand the numbers.

Edit
Report

1 Answer

3

That prompt probably meant:
In your current git branch - master, you had added two files +2, modified one ~1 and removed zero -0.
! signifies you are currently at the root of the repository. Check this comment for more info.

Not sure which shell you are using - But you may want to check the PROMPT and PS1 environment variables to find what those items mean in your prompt.

The prompt got reset to just [master] - once you had committed all the changes, as you mentioned in your questions.

PROMPT environment variable is the one used by the windows shell cmd, and PS1 is used by unixy shells - like bash.

Edit: Totally missed the powershell tag you put in there - I'm not a windows guy - but looks like in powershell you create a prompt function - check this link: http://www.johndcook.com/blog/2008/05/12/customizing-the-powershell-command-prompt/

answered 2012-08-18T19:19:14.563

Your Answer