| Index: third_party/typ/typ/host.py
|
| diff --git a/third_party/typ/typ/host.py b/third_party/typ/typ/host.py
|
| index c5f6ac8c8d4c94f39bd8a10a1ed50534d2203866..fc9e11304cdb47f4baafac2b52a0753f901dc402 100644
|
| --- a/third_party/typ/typ/host.py
|
| +++ b/third_party/typ/typ/host.py
|
| @@ -35,6 +35,7 @@ class Host(object):
|
| python_interpreter = sys.executable
|
| is_python3 = bool(sys.version_info.major == 3)
|
|
|
| + pathsep = os.pathsep
|
| sep = os.sep
|
| env = os.environ
|
|
|
| @@ -77,6 +78,11 @@ class Host(object):
|
| return proc.returncode, stdout.decode('utf-8'), stderr.decode('utf-8')
|
|
|
| def call_inline(self, argv, env=None):
|
| + if isinstance(self.stdout, _TeedStream): # pragma: no cover
|
| + ret, out, err = self.call(argv, env)
|
| + self.print_(out, end='')
|
| + self.print_(err, end='', stream=self.stderr)
|
| + return ret
|
| return subprocess.call(argv, stdin=self.stdin, stdout=self.stdout,
|
| stderr=self.stderr, env=env)
|
|
|
| @@ -126,6 +132,9 @@ class Host(object):
|
| if not self.exists(path):
|
| os.makedirs(path)
|
|
|
| + def mktempfile(self, delete=True):
|
| + return tempfile.NamedTemporaryFile(delete=delete)
|
| +
|
| def mkdtemp(self, **kwargs):
|
| return tempfile.mkdtemp(**kwargs)
|
|
|
|
|