repos: hg: Add real support for resolve_branch_cmd

Will be needed to unify invalid branch name detection.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
Jan Kiszka 2023-05-29 19:12:50 +02:00
parent f1f358bed5
commit 51846faef4

View File

@ -492,8 +492,8 @@ class MercurialRepo(RepoImpl):
return ['hg', 'diff'] return ['hg', 'diff']
def resolve_branch_cmd(self): def resolve_branch_cmd(self):
# We never need to care about creating tracking branches in mercurial return ['hg', 'identify', '--id', '-r', self.branch or self.refspec,
return ['false'] 'default']
def checkout_cmd(self, desired_ref, is_branch): def checkout_cmd(self, desired_ref, is_branch):
cmd = ['hg', 'checkout', desired_ref] cmd = ['hg', 'checkout', desired_ref]