Re: detached HEAD before root commit - possible?

2013-06-24 Thread Matthieu Moy
SZEDER Gábor writes: > I suspect that detaching HEAD before a root commit is not possible by > design. What would HEAD contain then!? 'git checkout' seems to > corroborate: > > $ git init > Initialized empty Git repository in /tmp/test/.git/ > $ git checkout --detach > fatal: You are on a branc

Re: detached HEAD before root commit - possible?

2013-06-23 Thread Junio C Hamano
Martin von Zweigbergk writes: > On Sun, Jun 23, 2013 at 4:54 PM, Jonathan Nieder wrote: >> >> In other words, HEAD always either points to an unborn or existing >> branch or an existing commit. It's not clear to me what it would >> mean to detach from an unborn branch. > > I think it should mea

Re: detached HEAD before root commit - possible?

2013-06-23 Thread Martin von Zweigbergk
On Sun, Jun 23, 2013 at 4:54 PM, Jonathan Nieder wrote: > > In other words, HEAD always either points to an unborn or existing > branch or an existing commit. It's not clear to me what it would > mean to detach from an unborn branch. I think it should mean that the next commit would be a root co

Re: detached HEAD before root commit - possible?

2013-06-23 Thread Jonathan Nieder
Hi, SZEDER Gábor wrote: > $ git init > Initialized empty Git repository in /tmp/test/.git/ > $ git checkout --detach > fatal: You are on a branch yet to be born > > Are there some plumbing commands and options that would still allow > this, or can I rely on that that it's impossible? gitreposito

detached HEAD before root commit - possible?

2013-06-23 Thread SZEDER Gábor
I suspect that detaching HEAD before a root commit is not possible by design. What would HEAD contain then!? 'git checkout' seems to corroborate: $ git init Initialized empty Git repository in /tmp/test/.git/ $ git checkout --detach fatal: You are on a branch yet to be born Are there some plumb