feat(updater): use nobackup option instead of backup
Some checks are pending
/ test (push) Waiting to run
Some checks are pending
/ test (push) Waiting to run
This commit is contained in:
parent
107bd64253
commit
a5c6a74f2b
2 changed files with 9 additions and 9 deletions
|
@ -39,11 +39,11 @@ if ($isRoot) {
|
|||
'description' => 'Update to latest version of stable yeswiki',
|
||||
'noValue' => true
|
||||
],
|
||||
'backup' => [
|
||||
'prefix' => 'b',
|
||||
'longPrefix' => 'backup',
|
||||
'description' => 'Save a backup in /root/yeswiki_backups folder before upgrading the yeswiki',
|
||||
'defaultValue' => true
|
||||
'nobackup' => [
|
||||
'prefix' => 'nobackup',
|
||||
'longPrefix' => 'nobackup',
|
||||
'description' => 'Do not save a backup in /root/yeswiki_backups folder before upgrading the yeswiki',
|
||||
'noValue' => true
|
||||
],
|
||||
'depth' => [
|
||||
'prefix' => 'd',
|
||||
|
@ -66,7 +66,7 @@ if ($isRoot) {
|
|||
try {
|
||||
$update = $climate->arguments->get('update');
|
||||
$output = $climate->arguments->get('output');
|
||||
$backup = $climate->arguments->get('backup');
|
||||
$nobackup = $climate->arguments->get('nobackup');
|
||||
$depth = $climate->arguments->get('depth');
|
||||
$matches = searchWikis($path, 'wakka.config.php', $depth);
|
||||
if (count($matches) == 0) {
|
||||
|
@ -94,7 +94,7 @@ if ($isRoot) {
|
|||
} elseif ($wiki['RELEASE'] == $version) {
|
||||
$climate->info('Skipping up-to-date wiki '.$wiki['URL']);
|
||||
} else {
|
||||
$climate->info(upgradeWiki($destDir, $wiki['PATH'], $backup));
|
||||
$climate->info(upgradeWiki($destDir, $wiki['PATH'], $nobackup));
|
||||
}
|
||||
}
|
||||
} else { // show yeswiki list info
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue