Skip to content

Commit b037191

Browse files
author
Petre Mierlutiu
committed
use tag's repr() in string format
1 parent b8eb297 commit b037191

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

setuptools_scm/hg.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
def _hg_tagdist_normalize_tagcommit(root, tag, dist, node):
99
dirty = node.endswith('+')
1010
node = node.strip('+')
11-
revset = ("(branch(.) and tag('{0}')::. and file('re:^(?!\.hgtags).*$')"
12-
" - tag('{0}'))").format(str(tag))
11+
revset = ("(branch(.) and tag({tag!r})::. and file('re:^(?!\.hgtags).*$')"
12+
" - tag({tag!r}))").format(tag=tag)
1313
if tag != '0.0':
1414
commits = do(['hg', 'log', '-r', revset, '--template', '{node|short}'],
1515
root)

0 commit comments

Comments
 (0)