# HG changeset patch # User Josef 'Jeff' Sipek # Date 1585256974 14400 # Node ID 7bbb83e4e8def14798da253e95600facb7f6586a # Parent c5653cf2811df157a68d9217c1e9679e24e7b8fc git: abort when attempting to set a branch Given the mapping we use (namely, a git head is a bookmark), it is better to error out with a hint. diff -r c5653cf2811d -r 7bbb83e4e8de hgext/git/dirstate.py --- a/hgext/git/dirstate.py Thu Mar 26 16:23:54 2020 -0400 +++ b/hgext/git/dirstate.py Thu Mar 26 17:09:34 2020 -0400 @@ -300,3 +300,8 @@ def clearbackup(self, tr, backupname): # TODO pass + + def setbranch(self, branch): + raise error.Abort( + b'git repos do not support branches. try using bookmarks' + )