@@ -48,6 +48,9 @@ |
||
48 | 48 | } |
49 | 49 | } |
50 | 50 | |
51 | + /** |
|
52 | + * @param string $environment |
|
53 | + */ |
|
51 | 54 | public function getAllValuesForEnvironment(?string $environment = null): array |
52 | 55 | { |
53 | 56 | $result = []; |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 | |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | $table->enableFormattingTags() |
48 | 48 | ->setHeaders(array($environment1, $environment2)) |
49 | 49 | ->displayKeys() |
50 | - ->setValueRenderingFunction(function($value){ |
|
50 | + ->setValueRenderingFunction(function($value) { |
|
51 | 51 | return $this->formatValue($value); |
52 | 52 | }); |
53 | 53 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 | |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | { |
37 | 37 | $unusedVariables = $processor->getUnusedVariables(); |
38 | 38 | |
39 | - if(! empty($unusedVariables)) |
|
39 | + if( ! empty($unusedVariables)) |
|
40 | 40 | { |
41 | 41 | $logger = $this->app['logger']; |
42 | 42 | |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | { |
54 | 54 | $unvaluedVariables = $processor->getUnvaluedVariables(); |
55 | 55 | |
56 | - if(! empty($unvaluedVariables)) |
|
56 | + if( ! empty($unvaluedVariables)) |
|
57 | 57 | { |
58 | 58 | $logger = $this->app['logger']; |
59 | 59 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Console; |
6 | 6 | |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | $sourcePath = $profile->getSourcePath(); |
108 | 108 | } |
109 | 109 | |
110 | - if(! is_array($sourcePath)) |
|
110 | + if( ! is_array($sourcePath)) |
|
111 | 111 | { |
112 | 112 | $sourcePath = [$sourcePath]; |
113 | 113 | } |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | { |
174 | 174 | $strings = $input->getOption($optionName); |
175 | 175 | |
176 | - if(! is_array($strings)) |
|
176 | + if( ! is_array($strings)) |
|
177 | 177 | { |
178 | 178 | $strings = [$strings]; |
179 | 179 | } |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | |
47 | 47 | public function enableExternalSupport(): self |
48 | 48 | { |
49 | - $this->parsers->enableExternalSupport($this->fs); |
|
49 | + $this->parsers->enableExternalSupport($this->fs); |
|
50 | 50 | |
51 | 51 | return $this; |
52 | 52 | } |
@@ -218,8 +218,8 @@ discard block |
||
218 | 218 | if($status['found'] === false) |
219 | 219 | { |
220 | 220 | $this->warning(sprintf( |
221 | - 'External file %s was not found', |
|
222 | - $file |
|
221 | + 'External file %s was not found', |
|
222 | + $file |
|
223 | 223 | )); |
224 | 224 | } |
225 | 225 | } |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Configuration; |
6 | 6 | |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | { |
84 | 84 | $files = [$masterFilePath]; |
85 | 85 | |
86 | - while(! empty($files)) |
|
86 | + while( ! empty($files)) |
|
87 | 87 | { |
88 | 88 | foreach($files as $file) |
89 | 89 | { |
@@ -135,7 +135,7 @@ discard block |
||
135 | 135 | |
136 | 136 | private function extractLines(string $filePath): array |
137 | 137 | { |
138 | - if(! $this->fs->has($filePath)) |
|
138 | + if( ! $this->fs->has($filePath)) |
|
139 | 139 | { |
140 | 140 | throw new \RuntimeException("$filePath does not exist"); |
141 | 141 | } |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Karma\Configuration; |
6 | 6 | |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | $this->variables = $variables; |
28 | 28 | |
29 | 29 | $this->externalReader = null; |
30 | - if(! empty($externalVariables)) |
|
30 | + if( ! empty($externalVariables)) |
|
31 | 31 | { |
32 | 32 | $this->externalReader = new Reader($externalVariables, [], $groups); |
33 | 33 | } |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | |
61 | 61 | if(in_array($environment, $this->groupNames)) |
62 | 62 | { |
63 | - if(! isset($this->defaultEnvironmentsForGroups[$environment])) |
|
63 | + if( ! isset($this->defaultEnvironmentsForGroups[$environment])) |
|
64 | 64 | { |
65 | 65 | throw new \RuntimeException(sprintf( |
66 | 66 | 'Group can not be used as environment (try with group %s detected)', |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | |
104 | 104 | private function accessVariable(string $variableName) |
105 | 105 | { |
106 | - if(! array_key_exists($variableName, $this->variables)) |
|
106 | + if( ! array_key_exists($variableName, $this->variables)) |
|
107 | 107 | { |
108 | 108 | throw new \RuntimeException(sprintf( |
109 | 109 | 'Unknown variable %s', |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | |
131 | 131 | private function processExternal(string $variable, string $environment) |
132 | 132 | { |
133 | - if(! $this->externalReader instanceof self) |
|
133 | + if( ! $this->externalReader instanceof self) |
|
134 | 134 | { |
135 | 135 | throw new \RuntimeException(sprintf( |
136 | 136 | 'There is no external variables. %s can not be resolve for environment %s', |