@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | |
41 | 41 | public function compileStaticPages(): void |
42 | 42 | { |
43 | - collect(Hyde::getDiscoveredPageTypes())->each(function (string $pageClass) { |
|
43 | + collect(Hyde::getDiscoveredPageTypes())->each(function(string $pageClass) { |
|
44 | 44 | $this->compilePagesForClass($pageClass); |
45 | 45 | }); |
46 | 46 | } |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | $this->needsDirectory(Hyde::sitePath('media')); |
63 | 63 | |
64 | 64 | $this->comment('Transferring Media Assets...'); |
65 | - $this->withProgressBar(DiscoveryService::getMediaAssetFiles(), function (string $filepath): void { |
|
65 | + $this->withProgressBar(DiscoveryService::getMediaAssetFiles(), function(string $filepath): void { |
|
66 | 66 | $sitePath = Hyde::sitePath('media/'.unslash(Str::after($filepath, Hyde::path('_media')))); |
67 | 67 | $this->needsParentDirectory($sitePath); |
68 | 68 | copy($filepath, $sitePath); |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | |
81 | 81 | $collection = $this->router->getRoutes($pageClass); |
82 | 82 | |
83 | - $this->withProgressBar($collection, function (Route $route): void { |
|
83 | + $this->withProgressBar($collection, function(Route $route): void { |
|
84 | 84 | (new StaticPageBuilder($route->getPage()))->__invoke(); |
85 | 85 | }); |
86 | 86 | |
@@ -94,7 +94,7 @@ discard block |
||
94 | 94 | |
95 | 95 | protected function isItSafeToCleanOutputDirectory(): bool |
96 | 96 | { |
97 | - if (! $this->isOutputDirectoryWhitelisted() && ! $this->askIfUnsafeDirectoryShouldBeEmptied()) { |
|
97 | + if (!$this->isOutputDirectoryWhitelisted() && !$this->askIfUnsafeDirectoryShouldBeEmptied()) { |
|
98 | 98 | $this->info('Output directory will not be emptied.'); |
99 | 99 | |
100 | 100 | return false; |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | |
37 | 37 | public function line(string $message = ''): self |
38 | 38 | { |
39 | - $this->write($message . PHP_EOL); |
|
39 | + $this->write($message.PHP_EOL); |
|
40 | 40 | |
41 | 41 | return $this; |
42 | 42 | } |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | { |
123 | 123 | protected function ansi(string $string, string $color): string |
124 | 124 | { |
125 | - return "\033[" . $color . 'm' . $string . "\033[0m"; |
|
125 | + return "\033[".$color.'m'.$string."\033[0m"; |
|
126 | 126 | } |
127 | 127 | |
128 | 128 | protected function black(string $string): string |
@@ -220,10 +220,10 @@ discard block |
||
220 | 220 | // Implode the rest of the tokens |
221 | 221 | $value = implode(': ', array_slice($tokens, 1)); |
222 | 222 | |
223 | - $this->outputString = static::lightGray('[') . static::main($tokens[0]) . static::lightGray(']'); |
|
223 | + $this->outputString = static::lightGray('[').static::main($tokens[0]).static::lightGray(']'); |
|
224 | 224 | |
225 | 225 | if (isset($tokens[1])) { |
226 | - $this->outputString .= ': ' . $value; |
|
226 | + $this->outputString .= ': '.$value; |
|
227 | 227 | } |
228 | 228 | |
229 | 229 | return $this->outputString; |
@@ -231,7 +231,7 @@ discard block |
||
231 | 231 | |
232 | 232 | private static function lightGray(string $string): string |
233 | 233 | { |
234 | - return "\033[0;90m" . $string . "\033[0m"; |
|
234 | + return "\033[0;90m".$string."\033[0m"; |
|
235 | 235 | } |
236 | 236 | |
237 | 237 | /** The primary color */ |
@@ -247,7 +247,7 @@ discard block |
||
247 | 247 | } |
248 | 248 | |
249 | 249 | // Gold (yellow) color |
250 | - return "\033[0;33m" . $string . "\033[0m"; |
|
250 | + return "\033[0;33m".$string."\033[0m"; |
|
251 | 251 | } |
252 | 252 | |
253 | 253 | public static function get(string $string): string |