@@ -56,7 +56,7 @@ |
||
56 | 56 | catch(ParseException $e) |
57 | 57 | { |
58 | 58 | throw new \RuntimeException(sprintf( |
59 | - 'Error while parsing profile : %s', |
|
59 | + 'Error while parsing profile : %s', |
|
60 | 60 | $e->getMessage() |
61 | 61 | )); |
62 | 62 | } |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | |
66 | 66 | foreach(array_keys($this->attributes) as $name) |
67 | 67 | { |
68 | - if(! isset($values[$name])) |
|
68 | + if( ! isset($values[$name])) |
|
69 | 69 | { |
70 | 70 | continue; |
71 | 71 | } |
@@ -196,7 +196,7 @@ discard block |
||
196 | 196 | return true; |
197 | 197 | } |
198 | 198 | |
199 | - if(! $parameterValidators[$parameter]($value)) |
|
199 | + if( ! $parameterValidators[$parameter]($value)) |
|
200 | 200 | { |
201 | 201 | throw new \RuntimeException('Paramater %s format is invalid'); |
202 | 202 | } |
@@ -191,8 +191,7 @@ |
||
191 | 191 | if( |
192 | 192 | ! array_key_exists($parameter, $parameterValidators) |
193 | 193 | || ! $parameterValidators[$parameter] instanceof \Closure |
194 | - ) |
|
195 | - { |
|
194 | + ) { |
|
196 | 195 | return true; |
197 | 196 | } |
198 | 197 |
@@ -123,7 +123,7 @@ |
||
123 | 123 | $titleLineNumber = count($lines); |
124 | 124 | |
125 | 125 | // ensure an empty line preceeds comment |
126 | - if(! empty($lines[$titleLineNumber - 1])) |
|
126 | + if( ! empty($lines[$titleLineNumber - 1])) |
|
127 | 127 | { |
128 | 128 | $lines[$titleLineNumber] = ''; |
129 | 129 | $titleLineNumber++; |
@@ -64,7 +64,7 @@ |
||
64 | 64 | $rootPath = ''; |
65 | 65 | } |
66 | 66 | |
67 | - if(! empty($rootPath)) |
|
67 | + if( ! empty($rootPath)) |
|
68 | 68 | { |
69 | 69 | $rootPath .= $directorySeparator; |
70 | 70 | } |
@@ -42,13 +42,13 @@ |
||
42 | 42 | |
43 | 43 | if($this->vcs->isTracked($targetFile)) |
44 | 44 | { |
45 | - $this->logger->info("Untrack $targetFile"); |
|
45 | + $this->logger->info("untrack $targetFile"); |
|
46 | 46 | $this->vcs->untrackFile($targetFile); |
47 | 47 | } |
48 | 48 | |
49 | 49 | if($this->vcs->isIgnored($targetFile) === false) |
50 | 50 | { |
51 | - $this->logger->info("Ignore $targetFile"); |
|
51 | + $this->logger->info("ignore $targetFile"); |
|
52 | 52 | $this->vcs->ignoreFile($targetFile); |
53 | 53 | } |
54 | 54 | } |
@@ -18,7 +18,7 @@ discard block |
||
18 | 18 | |
19 | 19 | public function read($key) |
20 | 20 | { |
21 | - if(! $this->exists($key)) |
|
21 | + if( ! $this->exists($key)) |
|
22 | 22 | { |
23 | 23 | return false; |
24 | 24 | } |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | |
44 | 44 | public function mtime($key) |
45 | 45 | { |
46 | - if(! $this->exists($key)) |
|
46 | + if( ! $this->exists($key)) |
|
47 | 47 | { |
48 | 48 | return false; |
49 | 49 | } |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | |
41 | 41 | public function setDefaultEnvironment($environment) |
42 | 42 | { |
43 | - if(! empty($environment) && is_string($environment)) |
|
43 | + if( ! empty($environment) && is_string($environment)) |
|
44 | 44 | { |
45 | 45 | $this->defaultEnvironment = $environment; |
46 | 46 | } |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | }, $value); |
96 | 96 | } |
97 | 97 | |
98 | - if(! is_string($value)) |
|
98 | + if( ! is_string($value)) |
|
99 | 99 | { |
100 | 100 | return $value; |
101 | 101 | } |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | |
113 | 113 | $paths = $c['sources.path']; |
114 | 114 | |
115 | - if(! is_array($paths)) |
|
115 | + if( ! is_array($paths)) |
|
116 | 116 | { |
117 | 117 | $paths = array($paths); |
118 | 118 | } |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | |
139 | 139 | $this['target.fileSystem.adapter'] = $this->factory(function($c) { |
140 | 140 | |
141 | - if(! empty($c['target.path'])) |
|
141 | + if( ! empty($c['target.path'])) |
|
142 | 142 | { |
143 | 143 | $c['hydrator.allowNonDistFilesOverwrite'] = true; |
144 | 144 | |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | $this['git'] = $this->factory($git); |
211 | 211 | $this['vcs'] = $this->factory($git); |
212 | 212 | |
213 | - $this['vcsHandler'] = $this->protect(function (Vcs $vcs) { |
|
213 | + $this['vcsHandler'] = $this->protect(function(Vcs $vcs) { |
|
214 | 214 | $handler = new VcsHandler($vcs, $this['finder']); |
215 | 215 | |
216 | 216 | $handler->setLogger($this['logger']) |
@@ -226,7 +226,7 @@ discard block |
||
226 | 226 | return new \Psr\Log\NullLogger(); |
227 | 227 | }); |
228 | 228 | |
229 | - $this['formatter.provider'] = function ($c) { |
|
229 | + $this['formatter.provider'] = function($c) { |
|
230 | 230 | return new ProfileProvider($c['profile']); |
231 | 231 | }; |
232 | 232 | |
@@ -240,19 +240,19 @@ discard block |
||
240 | 240 | return $hydrator; |
241 | 241 | }); |
242 | 242 | |
243 | - $this['generator.nameTranslator'] = function ($c) { |
|
243 | + $this['generator.nameTranslator'] = function($c) { |
|
244 | 244 | $translator = new FilePrefixTranslator(); |
245 | 245 | $translator->changeMasterFile($c['configuration.masterFile']); |
246 | 246 | |
247 | 247 | return $translator; |
248 | 248 | }; |
249 | 249 | |
250 | - $this['generator.variableProvider'] = $this->factory(function ($c) { |
|
250 | + $this['generator.variableProvider'] = $this->factory(function($c) { |
|
251 | 251 | $provider = new VariableProvider($c['parser'], $c['configuration.masterFile']); |
252 | 252 | |
253 | 253 | $profile = $c['profile']; |
254 | 254 | $options = $profile->getGeneratorOptions(); |
255 | - if(! isset($options['translator']) || $options['translator'] === 'prefix') |
|
255 | + if( ! isset($options['translator']) || $options['translator'] === 'prefix') |
|
256 | 256 | { |
257 | 257 | $provider->setNameTranslator($c['generator.nameTranslator']); |
258 | 258 | } |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | return $provider; |
261 | 261 | }); |
262 | 262 | |
263 | - $this['configurationFilesGenerator'] = function ($c) { |
|
263 | + $this['configurationFilesGenerator'] = function($c) { |
|
264 | 264 | return new YamlGenerator($c['sources.fileSystem'], $c['configuration'], $c['generator.variableProvider']); |
265 | 265 | }; |
266 | 266 | } |