Skip to content

Commit d50976f

Browse files
committed
Merge branch 'mr/eyraud/66' into 'master'
process.Run: consider the env parameter when computing the exec name Closes #66 See merge request it/e3-core!178
2 parents 2eb8812 + 331cf3b commit d50976f

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/e3/os/process.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,10 @@ def add_interpreter_command(cmd_line: CmdLine) -> CmdLine:
314314
"""
315315
if not parse_shebang:
316316
# nothing to do
317-
return [which(cmd_line[0], default=cmd_line[0])] + cmd_line[1:]
317+
paths = env["PATH"] if env and "PATH" in env else None
318+
return [
319+
which(cmd_line[0], paths=paths, default=cmd_line[0])
320+
] + cmd_line[1:]
318321

319322
prog = which(cmd_line[0], default=None)
320323
if prog is None:

0 commit comments

Comments
 (0)