Commit b9c15047 authored by marclaporte's avatar marclaporte

[MOD] Renaming Database Dump to Database Backup because I don't like the word...

[MOD] Renaming Database Dump to Database Backup because I don't like the word dump, as it has the connotation of waste or garbage http://en.wikipedia.org/wiki/Dump Backup is more universal. Part 2
parent b0403e1d
......@@ -59,11 +59,11 @@ $isInstalled = $installer->isInstalled();
if ($isInstalled) {
require_once 'tiki-setup.php';
$console->add(new Tiki\Command\CacheClearCommand);
$console->add(new Tiki\Command\DumpDBCommand);
$console->add(new Tiki\Command\BackupDBCommand);
$console->add(new Tiki\Command\BackupFilesCommand);
} else {
$console->add(new Tiki\Command\UnavailableCommand('cache:clear'));
$console->add(new Tiki\Command\UnavailableCommand('database:dump'));
$console->add(new Tiki\Command\UnavailableCommand('database:backup'));
$console->add(new Tiki\Command\UnavailableCommand('backup:files'));
}
......
......@@ -13,17 +13,17 @@ use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
class DumpDBCommand extends Command
class BackupDBCommand extends Command
{
protected function configure()
{
$this
->setName('database:dump')
->setDescription('Create a database dump')
->setName('database:backup')
->setDescription('Create a database backup')
->addArgument(
'path',
InputArgument::REQUIRED,
'Path to save dump (relative to console.php, or absolute)'
'Path to save backup (relative to console.php, or absolute)'
);
}
......@@ -63,6 +63,6 @@ class DumpDBCommand extends Command
$outputFile = $path . '/' . $dbs_tiki . '_' . date( 'Y-m-d_H:i:s' ) . '.sql.gz';
$command = "mysqldump --quick $args | gzip -5 > " . escapeshellarg( $outputFile );
exec( $command );
$output->writeln('<comment>Database dumped: '.$outputFile.'</comment>');
$output->writeln('<comment>Database backup completed: '.$outputFile.'</comment>');
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment