Completed
Pull Request — master (#524)
by
unknown
03:06
created
src/Task/Development/loadTasks.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
     }
68 68
 
69 69
     /**
70
-     * @param string|array $url
70
+     * @param string[] $url
71 71
      * @return OpenBrowser
72 72
      */
73 73
     protected function taskOpenBrowser($url)
Please login to merge, or discard this patch.
examples/RoboFile.php 4 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@
 block discarded – undo
15 15
  */
16 16
 class RoboFile extends \Robo\Tasks
17 17
 {
18
-   /**
18
+    /**
19 19
      * Watch a file.
20 20
      *
21 21
      * Demonstrates the 'watch' command. Runs 'composer update' any time
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -81,6 +81,9 @@
 block discarded – undo
81 81
         return false;
82 82
     }
83 83
 
84
+    /**
85
+     * @param string $message
86
+     */
84 87
     protected function printMessage($level, $message, $context = [])
85 88
     {
86 89
         $inProgress = $this->hideProgressIndicator();
Please login to merge, or discard this patch.
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
      */
32 32
     public function tryWatch()
33 33
     {
34
-        $this->taskWatch()->monitor(['composer.json', 'composer.lock'], function () {
34
+        $this->taskWatch()->monitor(['composer.json', 'composer.lock'], function() {
35 35
             $this->taskComposerUpdate()->run();
36 36
         })->run();
37 37
     }
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
     public function tryInput()
43 43
     {
44 44
         $answer = $this->ask('how are you?');
45
-        $this->say('You are '.$answer);
45
+        $this->say('You are ' . $answer);
46 46
         $yes = $this->confirm('Do you want one more question?');
47 47
         if (!$yes) {
48 48
             return Result::cancelled();
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
         $lang = $this->askDefault('what is your favorite scripting language?', 'PHP');
51 51
         $this->say($lang);
52 52
         $pin = $this->askHidden('Ok, now tell your PIN code (it is hidden)');
53
-        $this->yell('Ha-ha, your pin code is: '.$pin);
53
+        $this->yell('Ha-ha, your pin code is: ' . $pin);
54 54
         $this->say('Bye!');
55 55
     }
56 56
 
@@ -174,7 +174,7 @@  discard block
 block discarded – undo
174 174
         // using yaml or json output formats.
175 175
         $data->addRendererFunction(
176 176
             // n.b. There is a fourth parameter $rowData that may be added here.
177
-            function ($key, $cellData, FormatterOptions $options) {
177
+            function($key, $cellData, FormatterOptions $options) {
178 178
                 if ($key == 'name') {
179 179
                     return "<info>$cellData</>";
180 180
                 }
@@ -204,10 +204,10 @@  discard block
 block discarded – undo
204 204
     public function tryFormatters($somthing = 'default', $options = ['format' => 'table', 'fields' => ''])
205 205
     {
206 206
         $outputData = [
207
-            'en' => [ 'first' => 'One',  'second' => 'Two',  'third' => 'Three' ],
208
-            'de' => [ 'first' => 'Eins', 'second' => 'Zwei', 'third' => 'Drei'  ],
209
-            'jp' => [ 'first' => 'Ichi', 'second' => 'Ni',   'third' => 'San'   ],
210
-            'es' => [ 'first' => 'Uno',  'second' => 'Dos',  'third' => 'Tres'  ],
207
+            'en' => ['first' => 'One', 'second' => 'Two', 'third' => 'Three'],
208
+            'de' => ['first' => 'Eins', 'second' => 'Zwei', 'third' => 'Drei'],
209
+            'jp' => ['first' => 'Ichi', 'second' => 'Ni', 'third' => 'San'],
210
+            'es' => ['first' => 'Uno', 'second' => 'Dos', 'third' => 'Tres'],
211 211
         ];
212 212
         return new RowsOfFields($outputData);
213 213
     }
@@ -222,7 +222,7 @@  discard block
 block discarded – undo
222 222
     public function alterFormatters($result, CommandData $commandData)
223 223
     {
224 224
         if ($commandData->input()->getOption('french')) {
225
-            $result['fr'] = [ 'first' => 'Un',  'second' => 'Deux',  'third' => 'Trois'  ];
225
+            $result['fr'] = ['first' => 'Un', 'second' => 'Deux', 'third' => 'Trois'];
226 226
         }
227 227
 
228 228
         return $result;
@@ -377,7 +377,7 @@  discard block
 block discarded – undo
377 377
             ->taskForEach($processList)
378 378
                 ->iterationMessage('Processing {value}')
379 379
                 ->call(
380
-                    function ($value) use($delay) {
380
+                    function($value) use($delay) {
381 381
                         // TaskForEach::call should only be used to do
382 382
                         // non-Robo operations. To use Robo tasks in an
383 383
                         // iterator, @see TaskForEach::withBuilder.
@@ -399,7 +399,7 @@  discard block
 block discarded – undo
399 399
             ->taskCleanDir($workdir)
400 400
             ->taskForEach($processList)
401 401
                 ->withBuilder(
402
-                    function ($builder, $key, $value) use ($workdir) {
402
+                    function($builder, $key, $value) use ($workdir) {
403 403
                         return $builder
404 404
                             ->taskFilesystemStack()
405 405
                                 ->mkdir("$workdir/$value");
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,6 @@
 block discarded – undo
3 3
 
4 4
 use League\Container\Container;
5 5
 use League\Container\ContainerInterface;
6
-
7 6
 use Symfony\Component\Console\Input\InputInterface;
8 7
 use Symfony\Component\Console\Output\OutputInterface;
9 8
 use Symfony\Component\Console\Input\StringInput;
Please login to merge, or discard this patch.
src/Common/TimeKeeper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,6 +53,6 @@
 block discarded – undo
53 53
         if ($duration > self::MINUTE) {
54 54
             return gmdate("i:s", $duration);
55 55
         }
56
-        return round($duration, 3).'s';
56
+        return round($duration, 3) . 's';
57 57
     }
58 58
 }
Please login to merge, or discard this patch.
src/Common/DynamicParams.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
     public function __call($property, $args)
15 15
     {
16 16
         if (!property_exists($this, $property)) {
17
-            throw new \RuntimeException("Property $property in task ".get_class($this).' does not exists');
17
+            throw new \RuntimeException("Property $property in task " . get_class($this) . ' does not exists');
18 18
         }
19 19
 
20 20
         // toggle boolean values
Please login to merge, or discard this patch.
src/Task/Archive/Extract.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -223,6 +223,6 @@
 block discarded – undo
223 223
 
224 224
     protected static function getTmpDir()
225 225
     {
226
-        return getcwd().'/tmp'.rand().time();
226
+        return getcwd() . '/tmp' . rand() . time();
227 227
     }
228 228
 }
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -206,7 +206,7 @@
 block discarded – undo
206 206
     /**
207 207
      * @param string $filename
208 208
      *
209
-     * @return bool|string
209
+     * @return string|false
210 210
      */
211 211
     protected static function archiveType($filename)
212 212
     {
Please login to merge, or discard this patch.
src/Task/Base/ParallelExec.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -119,7 +119,7 @@
 block discarded – undo
119 119
             if ($p->getExitCode() === 0) {
120 120
                 continue;
121 121
             }
122
-            $errorMessage .= "'" . $p->getCommandLine() . "' exited with code ". $p->getExitCode()." \n";
122
+            $errorMessage .= "'" . $p->getCommandLine() . "' exited with code " . $p->getExitCode() . " \n";
123 123
             $exitCode = max($exitCode, $p->getExitCode());
124 124
         }
125 125
         if (!$errorMessage) {
Please login to merge, or discard this patch.
src/Task/Base/Exec.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -144,7 +144,7 @@
 block discarded – undo
144 144
         if (!$this->background and $this->isPrinted) {
145 145
             $this->startTimer();
146 146
             $this->process->run(
147
-                function ($type, $buffer) {
147
+                function($type, $buffer) {
148 148
                     $progressWasVisible = $this->hideTaskProgress();
149 149
                     print($buffer);
150 150
                     $this->showTaskProgress($progressWasVisible);
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@
 block discarded – undo
4 4
 trait loadTasks
5 5
 {
6 6
     /**
7
-     * @param string|\Robo\Contract\CommandInterface $command
7
+     * @param string $command
8 8
      *
9 9
      * @return Exec
10 10
      */
Please login to merge, or discard this patch.
src/Task/Testing/Atoum.php 2 patches
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,6 @@
 block discarded – undo
73 73
 
74 74
     /**
75 75
      * Path to the bootstrap file.
76
-
77 76
      * @param $file
78 77
      *
79 78
      * @return $this
Please login to merge, or discard this patch.
Doc Comments   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
     /**
49 49
      * Tag or Tags to filter.
50 50
      *
51
-     * @param string|array $tags
51
+     * @param string $tags
52 52
      *
53 53
      * @return $this
54 54
      */
@@ -125,6 +125,7 @@  discard block
 block discarded – undo
125 125
      * Test file or test files to run.
126 126
      *
127 127
      * @param string|array
128
+     * @param string[] $files
128 129
      *
129 130
      * @return $this
130 131
      */
@@ -137,6 +138,7 @@  discard block
 block discarded – undo
137 138
      * Test directory or directories to run.
138 139
      *
139 140
      * @param string|array A single directory or a list of directories.
141
+     * @param string $directories
140 142
      *
141 143
      * @return $this
142 144
      */
Please login to merge, or discard this patch.
src/Task/Simulator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@
 block discarded – undo
96 96
             return $this->shortenParameter(var_export($item, true));
97 97
         }
98 98
         if (is_object($item)) {
99
-            return '[' . get_class($item). ' object]';
99
+            return '[' . get_class($item) . ' object]';
100 100
         }
101 101
         if (is_string($item)) {
102 102
             return $this->shortenParameter("'$item'");
Please login to merge, or discard this patch.