@@ -45,7 +45,7 @@ |
||
| 45 | 45 | /** |
| 46 | 46 | * Get the services provided by the provider. |
| 47 | 47 | * |
| 48 | - * @return array |
|
| 48 | + * @return string[] |
|
| 49 | 49 | */ |
| 50 | 50 | public function provides() |
| 51 | 51 | { |
@@ -76,7 +76,7 @@ |
||
| 76 | 76 | $connectionParameters = config('tail.connections.'.$connection); |
| 77 | 77 | |
| 78 | 78 | if (isset($connectionParameters['port'])) { |
| 79 | - $portCommand = "-p {$connectionParameters['port']}"; |
|
| 79 | + $portCommand = "-p {$connectionParameters['port']}"; |
|
| 80 | 80 | } |
| 81 | 81 | |
| 82 | 82 | $this->guardAgainstInvalidConnectionParameters($connectionParameters); |
@@ -76,12 +76,12 @@ discard block |
||
| 76 | 76 | $connectionParameters = config('tail.connections.'.$connection); |
| 77 | 77 | |
| 78 | 78 | if (isset($connectionParameters['port'])) { |
| 79 | - $portCommand = "-p {$connectionParameters['port']}"; |
|
| 79 | + $portCommand = "-p {$connectionParameters['port']}"; |
|
| 80 | 80 | } |
| 81 | 81 | |
| 82 | 82 | $this->guardAgainstInvalidConnectionParameters($connectionParameters); |
| 83 | 83 | |
| 84 | - $tailCommand = 'ssh '.($connectionParameters['user'] == '' ? '' : $connectionParameters['user'].'@').$connectionParameters['host']." " . $portCommand . " -T 'cd ".$connectionParameters['logDirectory'].';tail -n '.$this->option('lines')." -f $(ls -t | head -n 1)'"; |
|
| 84 | + $tailCommand = 'ssh '.($connectionParameters['user'] == '' ? '' : $connectionParameters['user'].'@').$connectionParameters['host']." ".$portCommand." -T 'cd ".$connectionParameters['logDirectory'].';tail -n '.$this->option('lines')." -f $(ls -t | head -n 1)'"; |
|
| 85 | 85 | |
| 86 | 86 | $this->info('start tailing latest remote log on host '.$connectionParameters['host'].' (port '.$port.') in directory '.$connectionParameters['logDirectory']); |
| 87 | 87 | |
@@ -97,7 +97,7 @@ discard block |
||
| 97 | 97 | { |
| 98 | 98 | $output = $this->output; |
| 99 | 99 | |
| 100 | - (new Process($command))->setTimeout(null)->run(function ($type, $line) use ($output) { |
|
| 100 | + (new Process($command))->setTimeout(null)->run(function($type, $line) use ($output) { |
|
| 101 | 101 | $output->write($line); |
| 102 | 102 | }); |
| 103 | 103 | } |