@@ -57,7 +57,7 @@ |
||
57 | 57 | } |
58 | 58 | |
59 | 59 | if ($describe) { |
60 | - $output->writeln('Class: '. get_class($orchestratorDeploy)); |
|
60 | + $output->writeln('Class: '.get_class($orchestratorDeploy)); |
|
61 | 61 | $orchestratorDeploy->describe($output); |
62 | 62 | |
63 | 63 | } else { |
@@ -94,22 +94,22 @@ discard block |
||
94 | 94 | $self = new Orchestrator(); |
95 | 95 | $self->setMode(0755); |
96 | 96 | |
97 | - if (file_exists($package_path . 'public')) { |
|
97 | + if (file_exists($package_path.'public')) { |
|
98 | 98 | $destination = MODX_BASE_PATH; |
99 | 99 | if (isset($config['LCI_ORCHESTRATOR_PUBLIC_PATH']) && file_exists($config['LCI_ORCHESTRATOR_PUBLIC_PATH'])) { |
100 | 100 | $destination = $config['LCI_ORCHESTRATOR_PUBLIC_PATH']; |
101 | 101 | } |
102 | 102 | |
103 | - $self->copyDirectory($package_path . 'public', $destination); |
|
103 | + $self->copyDirectory($package_path.'public', $destination); |
|
104 | 104 | } |
105 | 105 | |
106 | - if (file_exists($package_path . 'assets')) { |
|
106 | + if (file_exists($package_path.'assets')) { |
|
107 | 107 | $destination = MODX_ASSETS_PATH; |
108 | 108 | if (isset($config['LCI_ORCHESTRATOR_ASSETS_PATH']) && file_exists($config['LCI_ORCHESTRATOR_ASSETS_PATH'])) { |
109 | 109 | $destination = $config['LCI_ORCHESTRATOR_ASSETS_PATH']; |
110 | 110 | } |
111 | 111 | |
112 | - $self->copyDirectory($package_path . 'assets', $destination); |
|
112 | + $self->copyDirectory($package_path.'assets', $destination); |
|
113 | 113 | } |
114 | 114 | } |
115 | 115 | |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | * |
120 | 120 | * @throws \LCI\Blend\Exception\MigratorException |
121 | 121 | */ |
122 | - public static function installComposerPackage($project, $type='master') |
|
122 | + public static function installComposerPackage($project, $type = 'master') |
|
123 | 123 | { |
124 | 124 | $path = static ::getPackagePath($project); |
125 | 125 | |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | * @param string $type |
134 | 134 | * @throws \LCI\Blend\Exception\MigratorException |
135 | 135 | */ |
136 | - public static function updateComposerPackage($project, $type='master') |
|
136 | + public static function updateComposerPackage($project, $type = 'master') |
|
137 | 137 | { |
138 | 138 | $path = static ::getPackagePath($project); |
139 | 139 | |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | { |
150 | 150 | static::loadOrchestratorPackageInfo(); |
151 | 151 | |
152 | - foreach(static::$packages as $existing_package) { |
|
152 | + foreach (static::$packages as $existing_package) { |
|
153 | 153 | static::updateComposerPackage($existing_package); |
154 | 154 | } |
155 | 155 | } |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | * @param string $type |
160 | 160 | * @throws \LCI\Blend\Exception\MigratorException |
161 | 161 | */ |
162 | - public static function uninstallComposerPackage($project, $type='master') |
|
162 | + public static function uninstallComposerPackage($project, $type = 'master') |
|
163 | 163 | { |
164 | 164 | $path = static ::getPackagePath($project); |
165 | 165 | |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | * |
177 | 177 | * @throws \LCI\Blend\Exception\MigratorException |
178 | 178 | */ |
179 | - protected static function runMigrations($project, $config=[], $method='up', $type='master') |
|
179 | + protected static function runMigrations($project, $config = [], $method = 'up', $type = 'master') |
|
180 | 180 | { |
181 | 181 | /** @var \LCI\MODX\Console\Console $console */ |
182 | 182 | $console = static::getConsole(); |
@@ -202,7 +202,7 @@ discard block |
||
202 | 202 | * @param bool $include_src |
203 | 203 | * @return string |
204 | 204 | */ |
205 | - protected static function getPackagePath($package='lci/orchestrator', $include_src = true) |
|
205 | + protected static function getPackagePath($package = 'lci/orchestrator', $include_src = true) |
|
206 | 206 | { |
207 | 207 | if (empty(static::$modx)) { |
208 | 208 | /** @var \LCI\MODX\Console\Console $console */ |
@@ -215,10 +215,10 @@ discard block |
||
215 | 215 | null, |
216 | 216 | (defined('MODX_CORE_PATH') ? MODX_CORE_PATH.'vendor/' : dirname(__DIR__)) |
217 | 217 | ); |
218 | - $path .= $package . DIRECTORY_SEPARATOR; |
|
218 | + $path .= $package.DIRECTORY_SEPARATOR; |
|
219 | 219 | |
220 | 220 | if ($include_src) { |
221 | - $path .= 'src' . DIRECTORY_SEPARATOR; |
|
221 | + $path .= 'src'.DIRECTORY_SEPARATOR; |
|
222 | 222 | } |
223 | 223 | |
224 | 224 | return $path; |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | if (!static::$packages) { |
253 | 253 | static::$packages = []; |
254 | 254 | |
255 | - static::$package_file = $console->getConfigFilePaths()['config_dir'] . 'lci_orchestrator_package.php'; |
|
255 | + static::$package_file = $console->getConfigFilePaths()['config_dir'].'lci_orchestrator_package.php'; |
|
256 | 256 | |
257 | 257 | if (file_exists(static::$package_file)) { |
258 | 258 | static::$packages = include static::$package_file; |
@@ -268,7 +268,7 @@ discard block |
||
268 | 268 | static::loadOrchestratorPackageInfo(); |
269 | 269 | if (in_array($package, static::$packages)) { |
270 | 270 | $temp = []; |
271 | - foreach(static::$packages as $existing_package) { |
|
271 | + foreach (static::$packages as $existing_package) { |
|
272 | 272 | if ($existing_package == $package) { |
273 | 273 | continue; |
274 | 274 | } |
@@ -300,8 +300,8 @@ discard block |
||
300 | 300 | */ |
301 | 301 | protected static function writeCacheFile($file, $data) |
302 | 302 | { |
303 | - $content = '<?php ' . PHP_EOL . |
|
304 | - 'return ' . var_export($data, true) . ';'; |
|
303 | + $content = '<?php '.PHP_EOL. |
|
304 | + 'return '.var_export($data, true).';'; |
|
305 | 305 | |
306 | 306 | file_put_contents($file, $content); |
307 | 307 | } |