[PATCH 3/4] remote-hg: try the 'tip' if no checkout present
- From
Felipe Contreras <felipe.contreras@gmail.com>
- Date
- Nov 12, 2012, 17:41 UTC
- Message-ID
- <1352742068-15346-4-git-send-email-felipe.contreras@gmail.com>
- In-Reply-To
- <1352742068-15346-1-git-send-email-felipe.contreras@gmail.com>
There's no concept of HEAD in mercurial, but let's try our best to do something sensible.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> --- contrib/remote-helpers/git-remote-hg | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/contrib/remote-helpers/git-remote-hg b/contrib/remote-helpers/git-remote-hg index c6d0367..3cdc1e2 100755 --- a/contrib/remote-helpers/git-remote-hg +++ b/contrib/remote-helpers/git-remote-hg @@ -440,6 +440,8 @@ def list_head(repo, cur): head = cur node = repo['.'] if not node: + node = repo['tip'] + if not node: return if head == 'default': head = 'master'
-- 1.8.0