Commit 71a1b7a6 by David Hotham Committed by GitHub

tell git not to use terminal prompts (#5880)

parent 9ca39b0a
from __future__ import annotations
import os
import subprocess
from typing import TYPE_CHECKING
......@@ -49,8 +50,14 @@ class SystemGit:
) + args
git_command = find_git_command()
env = os.environ.copy()
env["GIT_TERMINAL_PROMPT"] = "0"
return (
subprocess.check_output(git_command + list(args), stderr=subprocess.STDOUT)
subprocess.check_output(
git_command + list(args),
stderr=subprocess.STDOUT,
env=env,
)
.decode()
.strip()
)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment