Re: [PATCH v2] Fix fetch/pull when run without --update-head-ok

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Johannes Schindelin
Date: Tuesday, October 14, 2008 - 9:15 am

Hi,

On Tue, 14 Oct 2008, Shawn O. Pearce wrote:


Actually, get_branch() does _not_ validate.  Which is why it thinks that 
the current branch is "master" even if there is no commit yet.

OTOH, resolve_ref() reads the SHA-1 of the ref, which fails in the case 
that there has not been any commit yet.

Still, I think that it would be nice to allow "git pull origin 
master:master" in a freshly initied non-bare repository, so I like 
resolve_ref() better.

Ciao,
Dscho

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] fetch: refuse to fetch into the current branch in ..., Johannes Schindelin, (Sat Oct 11, 4:38 am)
Re: [PATCH] fetch: refuse to fetch into the current branch ..., Johannes Schindelin, (Mon Oct 13, 2:28 am)
[PATCH v2] Fix fetch/pull when run without --update-head-ok, Johannes Schindelin, (Mon Oct 13, 2:36 am)
Re: [PATCH v2] Fix fetch/pull when run without --update-he ..., Johannes Schindelin, (Mon Oct 13, 10:57 am)
Re: [PATCH v2] Fix fetch/pull when run without --update-he ..., Johannes Schindelin, (Mon Oct 13, 11:12 am)
Re: [PATCH v2] Fix fetch/pull when run without --update-he ..., Johannes Schindelin, (Tue Oct 14, 2:49 am)
Re: [PATCH v2] Fix fetch/pull when run without --update-he ..., Johannes Schindelin, (Tue Oct 14, 9:15 am)
Re: [PATCH v2] Fix fetch/pull when run without --update-he ..., Johannes Schindelin, (Tue Oct 14, 9:17 am)