protected function execute(InputInterface $input, OutputInterface $output)
{
$this->output = $output;
$this->detectMagento($output, true);
if (!$this->initMagento()) {
return;
}
$workingDirectory = getcwd();
$magentoRootFolder = $this->getApplication()->getMagentoRootFolder();
$cacheDir = $magentoRootFolder . '/var/cache';
$output->writeln(sprintf('<info>Flushing cache directory <comment>%s</comment></info>', $cacheDir));
$this->verbose(sprintf('<debug>root-dir: <comment>%s</comment>', $magentoRootFolder));
$this->verbose(sprintf('<debug>cwd: <comment>%s</comment>', $workingDirectory));
$this->emptyDirectory($cacheDir);
$output->writeln('Cache directory flushed');
}