Skip to content

Commit 4609225

Browse files
author
Greg Bowler
committed
tweak: initialise with existing environment
closes #50
1 parent e2964f4 commit 4609225

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/Process.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,13 @@ class Process {
1717
protected array $status;
1818
protected bool $isBlocking = false;
1919
/** @var array<string, string> */
20-
protected array $env = [];
20+
protected array $env;
2121

2222
public function __construct(string...$command) {
2323
$this->command = $command;
2424
$this->cwd = getcwd();
2525
$this->pipes = [];
26+
$this->env = getenv();
2627
}
2728

2829
public function __destruct() {

0 commit comments

Comments
 (0)