aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTreer <treer.git@the-bordello.com>2016-04-25 19:30:37 +1000
committerTreer <treer.git@the-bordello.com>2016-04-25 19:30:37 +1000
commit02ee7f17e8b634a9d0e195cce212d838eaaefe9f (patch)
treef28aa8599bc1d1fafd56f118560e0afea45260e4
parent78320ee3a611b414dfd685bf36dfb0553bb2f1e3 (diff)
downloadvolse-hubzilla-02ee7f17e8b634a9d0e195cce212d838eaaefe9f.tar.gz
volse-hubzilla-02ee7f17e8b634a9d0e195cce212d838eaaefe9f.tar.bz2
volse-hubzilla-02ee7f17e8b634a9d0e195cce212d838eaaefe9f.zip
add commandline help to util/pconfig
-rwxr-xr-xutil/pconfig34
1 files changed, 34 insertions, 0 deletions
diff --git a/util/pconfig b/util/pconfig
index 038fa74c3..802590f7a 100755
--- a/util/pconfig
+++ b/util/pconfig
@@ -8,6 +8,40 @@ require_once('include/zot.php');
cli_startup();
+$helpArgs = getopt('h', array('help'));
+if (count($helpArgs) === 1) {
+ echo <<<'EndOfOutput'
+Gets, sets, or lists personal (per channel) configuration settings.
+
+Usage: util/pconfig <channel_id>
+ util/pconfig <channel_id> <family>
+ util/pconfig <channel_id> <family> <key>
+ util/pconfig <channel_id> <family> <key> <value>
+
+ util/pconfig <channel_id>
+ Displays all of the the channel's config entries
+
+ util/pconfig <channel_id> <family>
+ Displays all of the channel's config entries for the specified family
+ (system, database, etc)
+
+ util/pconfig <channel_id> <family> <key>
+ Displays single config entry for the specified family and key
+
+ util/pconfig <channel_id> <family> <key> <value>
+ Set config entry for specified family and key to value and display result
+
+Notes:
+ For site-wide configuration settings, use util/config
+
+ Details for configuration options can be found at:
+
+EndOfOutput;
+ echo ' ' . App::get_baseurl() . '/help/hidden_configs' . PHP_EOL . PHP_EOL;
+ return;
+}
+
+
if($argc > 4) {
set_pconfig($argv[1],$argv[2],$argv[3],$argv[4]);
build_sync_packet($argv[1]);