protected function execute(InputInterface $input, OutputInterface $output)
{
$this->commandConfig = $this->getCommandConfig();
$this->writeSection($output, 'Magento Installation');
$this->precheckPhp();
if (!$input->getOption('noDownload')) {
$this->selectMagentoVersion($input, $output);
}
$this->chooseInstallationFolder($input, $output);
if (!$input->getOption('noDownload')) {
$result = $this->downloadMagento($input, $output);
if ($result === false) {
return 1;
}
}
if ($input->getOption('only-download')) {
return 0;
}
$this->createDatabase($input, $output);
if (!$input->getOption('noDownload')) {
$this->installSampleData($input, $output);
}
$this->removeEmptyFolders();
$this->setDirectoryPermissions($output);
$this->installMagento($input, $output, $this->config['installationFolder']);
}