From: Dan Brown Date: Mon, 1 May 2023 15:02:32 +0000 (+0100) Subject: Added improvements from testing on bsdemo X-Git-Url: http://source.bookstackapp.com/system-cli/commitdiff_plain/6066bc3c760e712549f8f3ac0e168ce5cd8a4670 Added improvements from testing on bsdemo - Updated default info text to be cyan instead of blue for readability. - Added "ZIP" in backup command details to make the file type clear. - Updated some really low MySQL timeouts. --- diff --git a/run.php b/run.php index 10ee64b..56d1952 100644 --- a/run.php +++ b/run.php @@ -17,7 +17,7 @@ $app = require __DIR__ . '/src/app.php'; $output = new ConsoleOutput(); $formatter = $output->getFormatter(); $formatter->setStyle('warn', new OutputFormatterStyle('yellow')); -$formatter->setStyle('info', new OutputFormatterStyle('blue')); +$formatter->setStyle('info', new OutputFormatterStyle('cyan')); $formatter->setStyle('success', new OutputFormatterStyle('green')); $formatter->setStyle('error', new OutputFormatterStyle('red')); diff --git a/src/Commands/BackupCommand.php b/src/Commands/BackupCommand.php index 39b3cdd..0c4f014 100644 --- a/src/Commands/BackupCommand.php +++ b/src/Commands/BackupCommand.php @@ -21,7 +21,7 @@ final class BackupCommand extends Command { $this->setName('backup'); $this->setDescription('Backup a BookStack installation to a single compressed ZIP file.'); - $this->addArgument('backup-path', InputArgument::OPTIONAL, 'Outfile file or directory to store the resulting backup file.', ''); + $this->addArgument('backup-path', InputArgument::OPTIONAL, 'Outfile file or directory to store the resulting backup ZIP file.', ''); $this->addOption('no-database', null, InputOption::VALUE_NONE, "Skip adding a database dump to the backup"); $this->addOption('no-uploads', null, InputOption::VALUE_NONE, "Skip adding uploaded files to the backup"); $this->addOption('no-themes', null, InputOption::VALUE_NONE, "Skip adding the themes folder to the backup"); diff --git a/src/Services/MySqlRunner.php b/src/Services/MySqlRunner.php index 5ccd5f8..8a91aad 100644 --- a/src/Services/MySqlRunner.php +++ b/src/Services/MySqlRunner.php @@ -32,8 +32,8 @@ class MySqlRunner { $output = (new ProgramRunner('mysql', '/usr/bin/mysql')) ->withEnvironment(['MYSQL_PWD' => $this->password]) - ->withTimeout(240) - ->withIdleTimeout(5) + ->withTimeout(300) + ->withIdleTimeout(300) ->runCapturingStdErr([ '-h', $this->host, '-P', $this->port,