From: W. Trevor King Date: Thu, 27 Mar 2014 15:57:48 GMT Subject: Re: Possible regression in master? (submodules without a "master" branch) Message-ID: <20140327155748.GN4008@odin.tremily.us> In-Reply-To: <20140327155208.GM4008@odin.tremily.us> On Thu, Mar 27, 2014 at 08:52:08AM -0700, W. Trevor King wrote: > Working around that to default to the upstream submodule's HEAD is > possible (you can just use --branch HEAD) Actually, this is probably not a good idea. The initial submodule addition works: $ git submodule add -b HEAD /tmp/submod.git submod Cloning into 'submod'... done. But subsequent log calls (from the superproject) do not: $ git log fatal: bad default revision 'HEAD' $ echo $? 128 and status calls (from the superproject) also have trouble: $ git status warning: refname 'HEAD' is ambiguous warning: refname 'HEAD' is ambiguous. On branch master … So it's better to just specify your preferred upstream branch directly (e.g. --branch next). Cheers, Trevor -- This email may be signed or encrypted with GnuPG (http://www.gnupg.org). For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy