src/Console/ChatCommand.php
protected function listenForConsoleCommands(InputInterface $input, OutputInterface $output, $message)
    {
        if ($message === '/quit') {
            $output->writeln('Exiting...');
            die();
        }

        if ($message === '/reload') {
            return $this->execute($input, $output);
        }

        if ($message === '/help') {
            $output->writeln('');
            $output->writeln('<comment>Usage:</comment>');
            $output->writeln('  Type a message and press Return to send.');
            $output->writeln('');
            $output->writeln('<comment>Commands:</comment>');
            $output->writeln('  <info>/help</info>        Show this text');
            $output->writeln('  <info>/reload</info>      Reload the interactive console');
            $output->writeln('  <info>/quit</info>        Quit the interative console');
            $output->writeln('');

            $this->waitForUserInput($input, $output);
        }

        return null;
    }
protected function listenForConsoleCommands(InputInterface $input, OutputInterface $output, $message)
    {
        if ($message === '/quit') {
            $output->writeln('Exiting...');
            die();
        }

        if ($message === '/reload') {
            return $this->execute($input, $output);
        }

        if ($message === '/help') {
            $output->writeln('');
            $output->writeln('<comment>Usage:</comment>');
            $output->writeln('  Type a message and press Return to send.');
            $output->writeln('');
            $output->writeln('<comment>Commands:</comment>');
            $output->writeln('  <info>/help</info>        Show this text');
            $output->writeln('  <info>/reload</info>      Reload the interactive console');
            $output->writeln('  <info>/quit</info>        Quit the interative console');
            $output->writeln('');

            $this->waitForUserInput($input, $output);
        }

        return null;
    }
protected function listenForConsoleCommands ( InputInterface $ input , OutputInterface $ output , $ message ) { if ( $ message === '/quit' ) { $ output -> writeln ( 'Exiting...' ) ; die ( ) ; } if ( $ message === '/reload' ) { return $ this -> execute ( $ input , $ output ) ; } if ( $ message === '/help' ) { $ output -> writeln ( '' ) ; $ output -> writeln ( '<comment>Usage:</comment>' ) ; $ output -> writeln ( '  Type a message and press Return to send.' ) ; $ output -> writeln ( '' ) ; $ output -> writeln ( '<comment>Commands:</comment>' ) ; $ output -> writeln ( '  <info>/help</info>        Show this text' ) ; $ output -> writeln ( '  <info>/reload</info>      Reload the interactive console' ) ; $ output -> writeln ( '  <info>/quit</info>        Quit the interative console' ) ; $ output -> writeln ( '' ) ; $ this -> waitForUserInput ( $ input , $ output ) ; } return null ; }
Listen for console commands before passing message to interpreter.

@param  InputInterface  $input
@param  OutputInterface  $output
@param  string  $message
@return null
Listen for console commands before passing message to interpreter .