BackupFiles
MMO\admin\helpers · 1 symbol · generated 30 Nov 2026
BackupFiles
BackupFiles.php:16A site's backups, where they are: on its server ({folder}/backups) and on this machine (what backup --fetch and backup-fetch brought), grouped into their sets (BackupSets) -- a set's encrypted copies (.age) with it --, and what deleting some of them, or keeping only the newest, takes away. Each place always keeps its newest complete set (every part the site's backup makes): no pick, nor any number to keep, reaches it.
- Namespace
MMO\admin\helpers
Index
| WHERE | where a site's backups are: its server's backups/, this machine's copies | |
| Inventory($target, $server, $local, $expects) static | A site's sets, in both places. | |
| Leaving($files) static | The files of a set that may leave the server: each part's encrypted copy when there is one, else its plain one -- but the configuration, which leaves encrypted or not at all (… | |
| Ordered($parts) static | ||
| Parse($target, $file) static | ||
| Plan($inventory, $pick) static | What deleting takes away. |
Constants1
WHERE
where a site's backups are: its server's backups/, this machine's copies
Methods5
Inventory($target, $server, $local, $expects)
staticBackupFiles.php:30A site's sets, in both places.
| $target | string | the site's name |
| $server | array | |
| $local | array | |
| $expects | array | the parts a complete set holds (BackupSets::PARTS): the site's backup makes them |
| returns | array | list<array{stamp: string, at: int, parts: list<string>, places: array<string, array{files: list<string>, size: int, parts: list<string>, complete: bool}>}>, others: list<array{file: string, size: int, at: int}>, protected: array<string, ?string>, totals: array<string, array{sets: int, size: int}>, expects: list<string>} the sets newest first; others the server's files of no set; protected each place's newest complete set |
Leaving($files)
staticBackupFiles.php:141The files of a set that may leave the server: each part's encrypted copy when there is one, else its plain one -- but the configuration, which leaves encrypted or not at all (SiteBackupTask).
Ordered($parts)
staticBackupFiles.php:165| $parts | array | |
| returns | array | parts in BackupSets::PARTS's order |
Parse($target, $file)
staticBackupFiles.php:158Plan($inventory, $pick)
staticBackupFiles.php:86What deleting takes away.
| $inventory | array | Inventory |
| $pick | array | |
| returns | array | list<string>, local: list<string>, kept: list<array{where: string, stamp: string, why: string}>, sets: array<string, list<string>>} the files to delete in each place; what was picked and is kept, and why; sets each place's sets deleted |
| throws | for nothing picked, a set or a file that is none, a number to keep below 1 |