Completed
Push — master ( 3bb399...1d27bd )
by Sebastian
03:10
created
src/Backup/Source/XtraBackup.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -140,11 +140,11 @@
 block discarded – undo
140 140
     {
141 141
         $executable = new Executable\Innobackupex($this->pathToXtraBackup);
142 142
         $executable->useHost($this->host)
143
-                   ->credentials($this->user, $this->password)
144
-                   ->dumpDatabases($this->databases)
145
-                   ->including($this->include)
146
-                   ->dumpFrom($this->dataDir)
147
-                   ->dumpTo($this->getDumpDir($target));
143
+                    ->credentials($this->user, $this->password)
144
+                    ->dumpDatabases($this->databases)
145
+                    ->including($this->include)
146
+                    ->dumpFrom($this->dataDir)
147
+                    ->dumpTo($this->getDumpDir($target));
148 148
         return $executable;
149 149
     }
150 150
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
         $result->debug($this->getExecutable($target)->getCommandPrintable());
124 124
 
125 125
         if (!$innobackupex->isSuccessful()) {
126
-            throw new Exception('XtraBackup failed: ' . $innobackupex->getStdErr());
126
+            throw new Exception('XtraBackup failed: '.$innobackupex->getStdErr());
127 127
         }
128 128
 
129 129
         return $this->createStatus($target);
@@ -167,6 +167,6 @@  discard block
 block discarded – undo
167 167
      */
168 168
     public function getDumpDir(Target $target) : string
169 169
     {
170
-        return $target->getPath() . '/dump';
170
+        return $target->getPath().'/dump';
171 171
     }
172 172
 }
Please login to merge, or discard this patch.
src/Backup/Source/Arangodump.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -161,13 +161,13 @@
 block discarded – undo
161 161
     {
162 162
         $executable = new Executable\Arangodump($this->pathToArangodump);
163 163
         $executable->useEndpoint($this->endpoint)
164
-                   ->credentials($this->username, $this->password)
165
-                   ->dumpDatabase($this->database)
166
-                   ->dumpCollections($this->collections)
167
-                   ->disableAuthentication($this->disableAuthentication)
168
-                   ->includeSystemCollections($this->includeSystemCollections)
169
-                   ->dumpData($this->dumpData)
170
-                   ->dumpTo($this->getDumpDir($target));
164
+                    ->credentials($this->username, $this->password)
165
+                    ->dumpDatabase($this->database)
166
+                    ->dumpCollections($this->collections)
167
+                    ->disableAuthentication($this->disableAuthentication)
168
+                    ->includeSystemCollections($this->includeSystemCollections)
169
+                    ->dumpData($this->dumpData)
170
+                    ->dumpTo($this->getDumpDir($target));
171 171
         return $executable;
172 172
     }
173 173
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
         $result->debug($arangodump->getCmdPrintable());
145 145
 
146 146
         if (!$arangodump->isSuccessful()) {
147
-            throw new Exception('arangodump failed: ' . $arangodump->getStdErr());
147
+            throw new Exception('arangodump failed: '.$arangodump->getStdErr());
148 148
         }
149 149
 
150 150
         return $this->createStatus($target);
@@ -190,6 +190,6 @@  discard block
 block discarded – undo
190 190
      */
191 191
     public function getDumpDir(Target $target) : string
192 192
     {
193
-        return $target->getPath() . '/dump';
193
+        return $target->getPath().'/dump';
194 194
     }
195 195
 }
Please login to merge, or discard this patch.
src/Backup/Sync/Rsync.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -96,12 +96,12 @@
 block discarded – undo
96 96
             );
97 97
         } else {
98 98
             $executable->fromPath($this->getRsyncLocation($target))
99
-                       ->toHost($this->host)
100
-                       ->toPath($this->path)
101
-                       ->toUser($this->user)
102
-                       ->compressed(!$target->shouldBeCompressed())
103
-                       ->removeDeleted($this->delete)
104
-                       ->exclude($this->excludes);
99
+                        ->toHost($this->host)
100
+                        ->toPath($this->path)
101
+                        ->toUser($this->user)
102
+                        ->compressed(!$target->shouldBeCompressed())
103
+                        ->removeDeleted($this->delete)
104
+                        ->exclude($this->excludes);
105 105
         }
106 106
         return $executable;
107 107
     }
Please login to merge, or discard this 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
         $result->debug($rsync->getCmd());
60 60
 
61 61
         if (!$rsync->isSuccessful()) {
62
-            throw new Exception('rsync failed: ' . $rsync->getStdErr());
62
+            throw new Exception('rsync failed: '.$rsync->getStdErr());
63 63
         }
64 64
     }
65 65
 
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
     public function simulate(Target $target, Result $result)
73 73
     {
74 74
         $result->debug(
75
-            'sync backup with rsync' . PHP_EOL
75
+            'sync backup with rsync'.PHP_EOL
76 76
             . $this->getExecutable($target)->getCommandPrintable()
77 77
         );
78 78
     }
Please login to merge, or discard this patch.
src/Backup/Compressor/Abstraction.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,14 +64,14 @@
 block discarded – undo
64 64
     public function compress(Target $target, Result $result)
65 65
     {
66 66
         if (!$this->isPathValid($this->path)) {
67
-            throw new Exception('path to compress should be valid: ' . $this->path);
67
+            throw new Exception('path to compress should be valid: '.$this->path);
68 68
         }
69 69
 
70 70
         $res = $this->execute($target);
71 71
         $result->debug($res->getCmd());
72 72
 
73 73
         if (!$res->isSuccessful()) {
74
-            throw new Exception('Failed to \'compress\' file: ' . $this->path);
74
+            throw new Exception('Failed to \'compress\' file: '.$this->path);
75 75
         }
76 76
 
77 77
         return $this->getArchiveFile($target);
Please login to merge, or discard this patch.
src/Backup/Compressor/Directory.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -72,10 +72,10 @@
 block discarded – undo
72 72
         $executable = new Tar($this->pathToCommand);
73 73
         $executable->archiveDirectory($this->path);
74 74
         $executable->archiveTo($this->getArchiveFile($target))
75
-                   ->useCompression(
76
-                       $target->shouldBeCompressed() ? $target->getCompression()->getCommand() : ''
77
-                   )
78
-                   ->removeSourceDirectory(true);
75
+                    ->useCompression(
76
+                        $target->shouldBeCompressed() ? $target->getCompression()->getCommand() : ''
77
+                    )
78
+                    ->removeSourceDirectory(true);
79 79
         return $executable;
80 80
     }
81 81
 
Please login to merge, or discard this patch.
src/Util/Cli.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
         'mongodump' => [],
43 43
         'mysqldump' => [
44 44
             '/usr/local/mysql/bin', // Mac OS X
45
-            '/usr/mysql/bin',       // Linux
45
+            '/usr/mysql/bin', // Linux
46 46
         ],
47 47
         'tar'       => [],
48 48
     ];
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
      */
120 120
     public static function detectCmdLocationInPath(string $cmd, string $path) : string
121 121
     {
122
-        $command = $path . DIRECTORY_SEPARATOR . $cmd;
122
+        $command = $path.DIRECTORY_SEPARATOR.$cmd;
123 123
         $bin     = self::isExecutable($command);
124 124
         if (empty($bin)) {
125 125
             throw new RuntimeException(sprintf('wrong path specified for \'%s\': %s', $cmd, $path));
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
     public static function detectCmdLocationInPaths($cmd, array $paths) : string
156 156
     {
157 157
         foreach ($paths as $path) {
158
-            $command = $path . DIRECTORY_SEPARATOR . $cmd;
158
+            $command = $path.DIRECTORY_SEPARATOR.$cmd;
159 159
             $bin     = self::isExecutable($command);
160 160
             if (null !== $bin) {
161 161
                 return $bin;
@@ -261,7 +261,7 @@  discard block
 block discarded – undo
261 261
             return $path;
262 262
         }
263 263
 
264
-        $file = $base . DIRECTORY_SEPARATOR . $path;
264
+        $file = $base.DIRECTORY_SEPARATOR.$path;
265 265
 
266 266
         if ($useIncludePath && !file_exists($file)) {
267 267
             $includePathFile = stream_resolve_include_path($path);
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
 
295 295
         $styledLines = [];
296 296
         foreach ($lines as $line) {
297
-            $styledLines[] = strlen($line) ? $style . str_pad($line, $padding) . "\x1b[0m" : '';
297
+            $styledLines[] = strlen($line) ? $style.str_pad($line, $padding)."\x1b[0m" : '';
298 298
         }
299 299
 
300 300
         return implode(PHP_EOL, $styledLines);
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
      */
310 310
     public static function formatWithAsterisk(string $buffer, int $length = 75) : string
311 311
     {
312
-        return $buffer . str_repeat('*', $length - strlen($buffer)) . PHP_EOL;
312
+        return $buffer.str_repeat('*', $length - strlen($buffer)).PHP_EOL;
313 313
     }
314 314
 
315 315
     /**
@@ -333,10 +333,10 @@  discard block
 block discarded – undo
333 333
             if ('.' === $file || '..' === $file) {
334 334
                 continue;
335 335
             }
336
-            if (is_dir($dir . '/' . $file)) {
337
-                self::removeDir($dir . '/' . $file);
336
+            if (is_dir($dir.'/'.$file)) {
337
+                self::removeDir($dir.'/'.$file);
338 338
             } else {
339
-                unlink($dir . '/' . $file);
339
+                unlink($dir.'/'.$file);
340 340
             }
341 341
         }
342 342
         rmdir($dir);
Please login to merge, or discard this patch.
src/Backup/Target.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
                 $this->pathElementsChanging[] = $d;
180 180
                 $foundChangingElement         = true;
181 181
             } else {
182
-                $this->pathNotChanging .= DIRECTORY_SEPARATOR . $d;
182
+                $this->pathNotChanging .= DIRECTORY_SEPARATOR.$d;
183 183
             }
184 184
         }
185 185
     }
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
      */
272 272
     public function getFilename(bool $plain = false) : string
273 273
     {
274
-        return $this->filename . $this->getFilenameSuffix($plain);
274
+        return $this->filename.$this->getFilenameSuffix($plain);
275 275
     }
276 276
 
277 277
     /**
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
      */
293 293
     public function getFilenameRaw($plain = false) : string
294 294
     {
295
-        return $this->filenameRaw . $this->getFilenameSuffix($plain);
295
+        return $this->filenameRaw.$this->getFilenameSuffix($plain);
296 296
     }
297 297
 
298 298
     /**
@@ -303,7 +303,7 @@  discard block
 block discarded – undo
303 303
      */
304 304
     public function getFilenameSuffix($plain = false) : string
305 305
     {
306
-        return $this->getSuffixToAppend() . ($plain ? '' : $this->getCompressionSuffix() . $this->getCrypterSuffix());
306
+        return $this->getSuffixToAppend().($plain ? '' : $this->getCompressionSuffix().$this->getCrypterSuffix());
307 307
     }
308 308
 
309 309
     /**
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
      */
314 314
     public function getSuffixToAppend() : string
315 315
     {
316
-        return count($this->fileSuffixes) ? '.' . implode('.', $this->fileSuffixes) : '';
316
+        return count($this->fileSuffixes) ? '.'.implode('.', $this->fileSuffixes) : '';
317 317
     }
318 318
 
319 319
     /**
@@ -323,7 +323,7 @@  discard block
 block discarded – undo
323 323
      */
324 324
     public function getCompressionSuffix() : string
325 325
     {
326
-        return $this->shouldBeCompressed() ? '.' . $this->compression->getSuffix() : '';
326
+        return $this->shouldBeCompressed() ? '.'.$this->compression->getSuffix() : '';
327 327
     }
328 328
 
329 329
     /**
@@ -333,7 +333,7 @@  discard block
 block discarded – undo
333 333
      */
334 334
     public function getCrypterSuffix() : string
335 335
     {
336
-        return $this->shouldBeEncrypted() ? '.' . $this->crypter->getSuffix() : '';
336
+        return $this->shouldBeEncrypted() ? '.'.$this->crypter->getSuffix() : '';
337 337
     }
338 338
 
339 339
     /**
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
      */
407 407
     public function getPathname(bool $plain = false) : string
408 408
     {
409
-        return $this->path . DIRECTORY_SEPARATOR . $this->getFilename($plain);
409
+        return $this->path.DIRECTORY_SEPARATOR.$this->getFilename($plain);
410 410
     }
411 411
 
412 412
     /**
Please login to merge, or discard this patch.
src/Configuration/Finder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,11 +64,11 @@
 block discarded – undo
64 64
     protected function findConfigurationInDir(string $path) : string
65 65
     {
66 66
         foreach ($this->defaultConfigNames as $file) {
67
-            $configurationFile = $path . DIRECTORY_SEPARATOR . $file;
67
+            $configurationFile = $path.DIRECTORY_SEPARATOR.$file;
68 68
             if (file_exists($configurationFile)) {
69 69
                 return realpath($configurationFile);
70 70
             }
71 71
         }
72
-        throw new Exception('Can\'t find configuration in directory \'' . $path . '\'.');
72
+        throw new Exception('Can\'t find configuration in directory \''.$path.'\'.');
73 73
     }
74 74
 }
Please login to merge, or discard this patch.
src/Runner/Bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
         if (!empty($filename)) {
42 42
             $pathToFile = stream_resolve_include_path($filename);
43 43
             if (!$pathToFile || !is_readable($pathToFile)) {
44
-                throw new Exception(sprintf('Cannot open bootstrap file "%s".' . PHP_EOL, $filename));
44
+                throw new Exception(sprintf('Cannot open bootstrap file "%s".'.PHP_EOL, $filename));
45 45
             }
46 46
             require $pathToFile;
47 47
         }
Please login to merge, or discard this patch.