protected function getCommand(Config $config, $index) { $type = $config->type; switch ($type) { case 'magento2': return "cd /var/www/public;bin/magento indexer:show-mode {$index}"; } return false; }