Re: The shared Git repo used by git-new-workdir

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 16.01.2012 19:57, Hilco Wijbenga wrote:
In my working directory:
hilco@centaur /mnt/lacie/workspaces/my-project-master
my-project-master (master $ u=)$ git status
# On branch master
nothing to commit (working directory clean)

In the shared repo:
hilco@centaur ~/git-clones/my-project my-project (master +$ u=)$ git status
# On branch master
# Changes to be committed:
#   (use "git reset HEAD<file>..." to unstage)
#
#       deleted:    .gitattributes
#       modified:   .gitignore
#       new file:   ...
... hundreds more ...

This is related to your using two repos with the same branch (irrespective of root repo or not).

There is nothing wrong with that per se, but if you add/commit/merge etc in one of those two, the working directory and index of the other repo doesn't get updated automatically. You would have to do "git reset --hard" in that repo to get it up-to-date

If you want to avoid this just don't check out the same branch in any two repos, root or not.




--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]