Re: git-show --stat on first commit
- From
Shawn Pearce <spearce@spearce.org>
- Date
- Nov 21, 2006, 18:34 UTC
- Message-ID
- <20061121183445.GA22283@spearce.org>
- In-Reply-To
- <20061121182135.GD7201@pasky.or.cz>
Petr Baudis <pasky@suse.cz> wrote:
Show 11 quoted lines
> BTW, the other frequent reason why empty commits come up so frequently > is a FAQ "how do I create an unrelated branch in my repository" - their > idea is that they will create a new branch starting with an empty commit > (of course noone would think of anything like that in inferior VCSes > because replacing the checked out trees would took forever; how cool Git > is!). > > (The answer is usually "create the branch in a separate repo and then > fetch it to the original one". But it feels a bit kludgy given the > otherwise seamless support for unrelated branches. (Not that I ever was > a big fan of unrelated long-lived branches in general.))
Or just abuse git-symbolic-ref:
rm .git/index git symbolic-ref HEAD refs/heads/unrelated-branch git add ... git commit ...
see, so simple. And no need to create an unrelated repository and pull across to this one...