Re: Re: [Bug report] 'git status' always says "Your branch is up-to-date with 'origin/master'"
- From
Jiang Xin <worldhello.net@gmail.com>
- Date
- Jan 6, 2014, 09:04 UTC
- Message-ID
- <CANYiYbH46EiS5iCEzGOi58Kgr+aCz_67vHsvRu=xSfuYUxosRg@mail.gmail.com>
- In-Reply-To
- <1963290835.719443.1388996669450.JavaMail.ngmail@webmail15.arcor-online.net>
2014/1/6 Thomas Ackermann <th.acker@arcor.de>:
Show 15 quoted lines
> > Hi Jiang, > > this happens with all of my repo clones (I am using V1.8.5.2 > on Windows and on Linux). Steps to reproduce: > > mkdir repo_a && cd repo_a && git init . > echo "1">foo && git add foo && git commit -m "1" > cd .. > git clone repo_a repo_b > cd repo_a > echo "2">foo && git add foo && git commit -m "2" > cd ../repo_b > git status > git checkout -b "branch"
Oops. Do
git fetch
then
git checkout master
You will get what you want.
Show 6 quoted lines
> git checkout master > > 'git status' and 'git checkout master' in repo_b are now > reporting "Your branch is up-to-date with 'origin/master'" > which is obviously wrong. >
-- Jiang Xin