From d485b752ce6ba3abfac99534f528eb6c8aa1e8bf Mon Sep 17 00:00:00 2001 From: Sebastien Vincent Date: Sat, 29 Feb 2020 12:38:06 +0100 Subject: [PATCH] Fix build outside git. --- defines.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/defines.py b/defines.py index 5483ce67..46dd1869 100644 --- a/defines.py +++ b/defines.py @@ -39,11 +39,11 @@ def repository_root(self): if ('APPVEYOR' in os.environ) or self.no_git: self._repository_root = self.local_path else: - self._repository_root = os.path.abspath(check_output(['git', 'rev-parse', '--show-toplevel']).rstrip()) + self._repository_root = os.path.abspath(check_output(['git', 'rev-parse', '--show-toplevel']).rstrip()).decode('utf-8') except (CalledProcessError, OSError): self._repository_root = os.path.abspath(os.path.dirname(inspect.getfile(inspect.currentframe()))) - return self._repository_root.decode('utf-8') + return self._repository_root @property def repository_version(self):