line('Копий нет. Сделать: php bin/proton backup:create'); return 0; } $check = $this->hasOption('check'); $rows = []; foreach ($files as $file) { $row = [$file['name'], Backup::size($file['size']), $file['created']]; if ($check) { $result = Backup::verify($file['name']); $row[] = ($result['ok'] ? 'годна' : 'НЕГОДНА') . ' — ' . $result['message']; } $rows[] = $row; } $headers = ['Файл', 'Размер', 'Когда']; if ($check) { $headers[] = 'Проверка'; } $this->table($headers, $rows); $this->line(); $this->line('Каталог: ' . Backup::directory()); $this->line('Держим копий: ' . (int) Config::get('backup.keep', 7)); $at = trim((string) Config::get('backup.schedule', '')); $this->line('По расписанию: ' . ($at !== '' ? 'каждый день в ' . $at : 'выключено (BACKUP_SCHEDULE)')); return 0; } }