From: Linus Torvalds Date: Wed, 22 Jan 2014 22:07:58 GMT Subject: Re: [RFC PATCH] Make 'git request-pull' more strict about matching local/remote branches Message-ID: In-Reply-To: On Wed, Jan 22, 2014 at 2:03 PM, Linus Torvalds wrote: > > Any ideas? The hacky way is to do "| head -1" to take the first > show-ref output, and then check if you get a different result if you > re-do it using "show-ref --tags". But that sounds really excessively > hacky. Is there a good way to do it? Using "git show-refs --tags --heads" would work for the common case (since that ignores remote branches), but would then disallow remote branches entirely. That might be ok in practice, but it's definitely wrong too. I'm probably missing some obvious solution. Linus