Skip to content

Commit 3f9ba57

Browse files
committed
Run git rev-parse in the correct cwd
1 parent 218ea98 commit 3f9ba57

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

snooty/parser.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,7 @@ def __init__(self,
272272
username = pwd.getpwuid(os.getuid()).pw_name
273273
branch = subprocess.check_output(
274274
['git', 'rev-parse', '--abbrev-ref', 'HEAD'],
275+
cwd=root,
275276
encoding='utf-8').strip()
276277
self.prefix = [self.config.name, username, branch]
277278

0 commit comments

Comments
 (0)