diff --git a/hgext/fix.py b/hgext/fix.py --- a/hgext/fix.py +++ b/hgext/fix.py @@ -540,12 +540,14 @@ May return None if there is no appropriate command to run for the given parameters. """ - parts = [self._command.format(rootpath=path, - basename=os.path.basename(path))] + parts = [pycompat.sysstr(self._command).format( + rootpath=path, + basename=os.path.basename(path))] if self._linerange: if not ranges: # No line ranges to fix, so don't run the fixer. return None for first, last in ranges: - parts.append(self._linerange.format(first=first, last=last)) - return ' '.join(parts) + parts.append(pycompat.sysstr(self._linerange).format( + first=first, last=last)) + return ' '.join(pycompat.sysbytes(b) for b in parts)