mirror of
https://github.com/PrivateBin/PrivateBin.git
synced 2024-10-01 01:26:10 -04:00
improve documentation
This commit is contained in:
parent
5c43ab6ef8
commit
5de779a989
@ -125,13 +125,14 @@ class Administration
|
||||
{
|
||||
echo <<<'EOT'
|
||||
Usage:
|
||||
administration [--delete <paste id> | --empty-dirs | --help | --statistics]
|
||||
administration [--delete <paste id> | --empty-dirs | --help | --purge | --statistics]
|
||||
|
||||
Options:
|
||||
-d, --delete deletes the requested paste ID
|
||||
-e, --empty-dirs removes empty directories (only if Filesystem storage is
|
||||
configured)
|
||||
-h, --help displays this help message
|
||||
-p, --purge purge all expired pastes
|
||||
-s, --statistics reads all stored pastes and comments and reports statistics
|
||||
EOT, PHP_EOL;
|
||||
exit($code);
|
||||
|
12
bin/migrate
12
bin/migrate
@ -17,13 +17,14 @@ if (version_compare(PHP_VERSION, '7.1.0') < 0) {
|
||||
|
||||
$longopts = array(
|
||||
"delete-after",
|
||||
"delete-during"
|
||||
"delete-during",
|
||||
"help"
|
||||
);
|
||||
$opts_arr = getopt("fhnv", $longopts, $rest);
|
||||
if ($opts_arr === false) {
|
||||
dieerr("Erroneous command line options. Please use -h");
|
||||
dieerr("Erroneous command line options. Please use --help");
|
||||
}
|
||||
if (array_key_exists("h", $opts_arr)) {
|
||||
if (array_key_exists("h", $opts_arr) || array_key_exists("help", $opts_arr)) {
|
||||
helpexit();
|
||||
}
|
||||
|
||||
@ -173,12 +174,12 @@ function debug ($text) {
|
||||
|
||||
function helpexit ()
|
||||
{
|
||||
print("migrate.php - Copy data between PrivateBin backends
|
||||
print("migrate - Copy data between PrivateBin backends
|
||||
|
||||
Usage:
|
||||
migrate [--delete-after] [--delete-during] [-f] [-n] [-v] srcconfdir
|
||||
[<dstconfdir>]
|
||||
migrate [-h]
|
||||
migrate [-h|--help]
|
||||
|
||||
Options:
|
||||
--delete-after delete data from source after all pastes and comments have
|
||||
@ -187,6 +188,7 @@ Options:
|
||||
comments have successfully been copied to the destination
|
||||
-f forcefully overwrite data which already exists at the
|
||||
destination
|
||||
-h, --help displays this help message
|
||||
-n dry run, do not copy data
|
||||
-v be verbose
|
||||
<srcconfdir> use storage backend configration from conf.php found in
|
||||
|
Loading…
Reference in New Issue
Block a user