Re: How to check new commit availability without full fetch?
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 11, 2010, 02:08 UTC
- Message-ID
- <7vk4vpcs1q.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <be6fef0d1001101757w7f54c9b2ye58c66179137efb1@mail.gmail.com>
Tay Ray Chuan <rctay89@gmail.com> writes:
Show 14 quoted lines
> By default, when you add a remote (with git remote add), git sets up > the fetch refspec in your config that looks like > > [remote "foo"] > url = git://foo.com/git/foo.git > fetch = refs/heads/*:refs/remotes/foo/* > > That is to say, branches on the remote repo will be fetched into a > "safe" area, refs/remotes/foo/, away from the branches that you > normally work with in refs/heads/. > > However, if you have a different config and you're fetching directly > into refs/heads/, then I can see why you would want to "peek" first > with --dry-run before fetching.
I don't. Until all the objects are safely transferred, none of the refs are updated, whether they are directly slurped into local branch namespace or remote tracking branch namespace. So no matter what the configuration is, interrupted transfer, forced or otherwise, is safe.