argument('type') === 'false' || $this->argument('type') === 'true') { $process = new Process('php misc/update/nix/tmux/stop.php'); $process->setTimeout(600); $process->run(function ($type, $buffer) { if (Process::ERR === $type) { echo 'ERR > ' . $buffer; } else { echo $buffer; } } ); if ($this->argument('type') === 'true') { $sessionName = Tmux::value('tmux_session'); $tmuxSession = new Process('tmux kill-session -t ' . $sessionName); $this->info('Killing active tmux session: ' . $sessionName); $tmuxSession->run(function ($type, $buffer) { if (Process::ERR === $type) { echo 'ERR > ' . $buffer; } else { echo $buffer; } } ); } }else { $this->error($this->description); } } }