Skip to content

Commit 44c5416

Browse files
committed
Updated the styles for the "cache:warmup" command
1 parent 08b2959 commit 44c5416

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/Symfony/Bundle/FrameworkBundle/Command/CacheWarmupCommand.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Symfony\Component\Console\Input\InputInterface;
1515
use Symfony\Component\Console\Input\InputOption;
1616
use Symfony\Component\Console\Output\OutputInterface;
17+
use Symfony\Component\Console\Style\SymfonyStyle;
1718

1819
/**
1920
* Warmup the cache.
@@ -53,8 +54,10 @@ protected function configure()
5354
*/
5455
protected function execute(InputInterface $input, OutputInterface $output)
5556
{
57+
$output = new SymfonyStyle($input, $output);
58+
5659
$kernel = $this->getContainer()->get('kernel');
57-
$output->writeln(sprintf('Warming up the cache for the <info>%s</info> environment with debug <info>%s</info>', $kernel->getEnvironment(), var_export($kernel->isDebug(), true)));
60+
$output->comment(sprintf('Warming up the cache for the <info>%s</info> environment with debug <info>%s</info>', $kernel->getEnvironment(), var_export($kernel->isDebug(), true)));
5861

5962
$warmer = $this->getContainer()->get('cache_warmer');
6063

@@ -63,5 +66,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
6366
}
6467

6568
$warmer->warmUp($this->getContainer()->getParameter('kernel.cache_dir'));
69+
70+
$output->success(sprintf('Cache for the "%s" environment (debug=%s) was succesfully warmed.', $kernel->getEnvironment(), var_export($kernel->isDebug(), true)));
6671
}
6772
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy