Completed
Push — master ( e5e1f1...768fd3 )
by Steve
04:00
created
src/Mvi/Command/MviCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,6 +33,6 @@
 block discarded – undo
33 33
     public function __construct($name = null)
34 34
     {
35 35
         parent::__construct($name);
36
-        $this->baseDir = realpath(__DIR__ . DS . '..' . DS . '..' . DS . '..');
36
+        $this->baseDir = realpath(__DIR__.DS.'..'.DS.'..'.DS.'..');
37 37
     }
38 38
 }
Please login to merge, or discard this patch.
src/Mvi/Command/UniqueCommand.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -97,9 +97,9 @@  discard block
 block discarded – undo
97 97
     protected function collectData()
98 98
     {
99 99
         $data = [];
100
-        foreach (glob($this->baseDir . DS . self::DIR_MD5 . DS . 'magento-*') as $release) {
100
+        foreach (glob($this->baseDir.DS.self::DIR_MD5.DS.'magento-*') as $release) {
101 101
             $lines   = explode("\n", file_get_contents($release));
102
-            $release = str_replace($this->baseDir . DS . self::DIR_MD5 . DS . 'magento-', '', $release);
102
+            $release = str_replace($this->baseDir.DS.self::DIR_MD5.DS.'magento-', '', $release);
103 103
             $data[$release] = [];
104 104
             foreach ($lines as $line) {
105 105
                 if (strlen($line) === 0) {
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
                 $counts[$file][$hash][] = $release;
153 153
             }
154 154
         }
155
-        uasort($counts, function ($a, $b) {
155
+        uasort($counts, function($a, $b) {
156 156
             return count($b) - count($a);
157 157
         });
158 158
         return $counts;
@@ -235,10 +235,10 @@  discard block
 block discarded – undo
235 235
      */
236 236
     protected function saveUniqueVersions($fingerprints)
237 237
     {
238
-        uasort($fingerprints, function ($a, $b) {
238
+        uasort($fingerprints, function($a, $b) {
239 239
             return count($b) - count($a);
240 240
         });
241 241
         $json = str_replace('\\/', '/', json_encode($fingerprints, JSON_PRETTY_PRINT));
242
-        return file_put_contents($this->baseDir . DS . self::VERSION_DESTINATION, $json);
242
+        return file_put_contents($this->baseDir.DS.self::VERSION_DESTINATION, $json);
243 243
     }
244 244
 }
Please login to merge, or discard this patch.
src/Mvi/Command/GenerateCommand.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
     protected function getReleases()
100 100
     {
101 101
         $names = [];
102
-        foreach (glob($this->baseDir . DS . self::DIR_RELEASE . DS . '*') as $name) {
102
+        foreach (glob($this->baseDir.DS.self::DIR_RELEASE.DS.'*') as $name) {
103 103
             $name = explode(DS, $name);
104 104
             $names[] = $name[count($name) - 1];
105 105
         }
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
             }
129 129
         }
130 130
         return file_put_contents(
131
-            $this->baseDir . DS . self::DIR_MD5 . DS . $release,
131
+            $this->baseDir.DS.self::DIR_MD5.DS.$release,
132 132
             implode("\n", array_merge($hashes, array('')))
133 133
         );
134 134
     }
@@ -143,10 +143,10 @@  discard block
 block discarded – undo
143 143
      */
144 144
     protected function getFiles($release, $folder)
145 145
     {
146
-        $path    = $this->baseDir . DS . self::DIR_RELEASE . DS . $release . DS;
146
+        $path    = $this->baseDir.DS.self::DIR_RELEASE.DS.$release.DS;
147 147
         $matches = [];
148
-        if (is_dir($path . $folder)) {
149
-            $directory = new \RecursiveDirectoryIterator($path . $folder . DS);
148
+        if (is_dir($path.$folder)) {
149
+            $directory = new \RecursiveDirectoryIterator($path.$folder.DS);
150 150
             $iterator  = new \RecursiveIteratorIterator($directory);
151 151
             foreach ($iterator as $file) {
152 152
                 if (in_array($file->getFilename(), array('.', '..'))) {
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
      */
169 169
     protected function getHash($release, $file)
170 170
     {
171
-        return md5(file_get_contents($this->baseDir . DS . self::DIR_RELEASE . DS . $release . DS . $file))
172
-            . ' ' . $file;
171
+        return md5(file_get_contents($this->baseDir.DS.self::DIR_RELEASE.DS.$release.DS.$file))
172
+            . ' '.$file;
173 173
     }
174 174
 }
Please login to merge, or discard this patch.
src/Mvi/Check.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     {
60 60
         $versions = $this->getVersions();
61 61
         foreach ($versions as $file => $hash) {
62
-            $md5 = md5(@file_get_contents($this->url . $file));
62
+            $md5 = md5(@file_get_contents($this->url.$file));
63 63
             if (isset($hash[$md5])) {
64 64
                 return $hash[$md5];
65 65
             }
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
     public function getVersions()
76 76
     {
77 77
         return json_decode(
78
-            file_get_contents(dirname(dirname(__DIR__)) . DIRECTORY_SEPARATOR . 'version.json'),
78
+            file_get_contents(dirname(dirname(__DIR__)).DIRECTORY_SEPARATOR.'version.json'),
79 79
             true
80 80
         );
81 81
     }
Please login to merge, or discard this patch.
src/bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 
13 13
 define('DS', DIRECTORY_SEPARATOR);
14 14
 
15
-require_once __DIR__ . '/../vendor/autoload.php';
15
+require_once __DIR__.'/../vendor/autoload.php';
16 16
 
17 17
 use Mvi\Command\CheckCommand;
18 18
 use Mvi\Command\GenerateCommand;
Please login to merge, or discard this patch.