Re: How to check new commit availability without full fetch?

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: How to check new commit availability without full fetch?

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:47:59

Tay Ray Chuan [off-list ref] writes:
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.

Re: How to check new commit availability without full fetch?

From: Michael Witten <hidden>
Date: 2016-06-15 22:47:59

On Sun, Jan 10, 2010 at 8:08 PM, Junio C Hamano [off-list ref] wrote:
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.
I suggest adding this kind of information to the fetch/pull (and I
suppose push) documentation.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help