blob: 39dc97638eda0d045a37f23fe26b8e36c80a07f6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#!/usr/bin/php
<?php
require(__DIR__ . '/_cli.php');
$options = getopt('', array(
'user:',
));
if (empty($options['user'])) {
fail('Usage: ' . basename(__FILE__) . " --user username");
}
$username = cliInitUser($options['user']);
echo 'FreshRSS optimizing database for user “', $username, "”…\n";
$databaseDAO = FreshRSS_Factory::createDatabaseDAO($username);
$ok = $databaseDAO->optimize();
done($ok);
|