From f19a36856ba8ef791a078b5585e740023e6d67a4 Mon Sep 17 00:00:00 2001 From: Alexandre Janniaux Date: Thu, 27 Apr 2023 13:35:34 +0200 Subject: [PATCH] install/inc: add some usage documentation Change the way the existing script syntax is documented and add the syntax and options for the step2.php script. --- htdocs/install/inc.php | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/htdocs/install/inc.php b/htdocs/install/inc.php index dcd2462b14f..ed1f3f93ad2 100644 --- a/htdocs/install/inc.php +++ b/htdocs/install/inc.php @@ -93,9 +93,20 @@ $long_options = array( function usage($program, $header) { echo $header."\n"; - echo " php ".$program." [options] previous_version new_version [script options]\n"; + echo " php ".$program." [options] [script options]\n"; echo "\n"; - echo "Script options when using upgrade.php:\n"; + echo "Script syntax when using step2.php:\n"; + echo " php ".$program." [options] [action] [selectlang]\n"; + echo "\n"; + echo " action:\n"; + echo " Specify the action to execute for the file among the following ones.\n"; + echo " - set: Create tables, keys, functions and data for the instance.\n"; + echo "\n"; + echo " selectlang:\n"; + echo " Setup the default lang to use, default to 'auto'.\n"; + echo "\n"; + echo "Script syntax when using upgrade.php:\n"; + echo " php ".$program." [options] previous_version new_version [script options]\n"; echo "\n"; echo " dirmodule:\n"; echo " Specify dirmodule to provide a path for an external module\n"; @@ -105,10 +116,11 @@ function usage($program, $header) echo " Allow to run migration even if database version does\n"; echo " not match start version of migration.\n"; echo "\n"; - echo "Script options when using upgrade2.php:\n"; + echo "Script syntax when using upgrade2.php:\n"; + echo " php ".$program." [options] previous_version new_version [module list]\n"; echo "\n"; - echo " MODULE_NAME1_TO_ENABLE,MODULE_NAME2_TO_ENABLE:\n"; - echo " Specify a list of module-name to enable, joined by comma.\n"; + echo " MAIN_MODULE_NAME1,MAIN_MODULE_NAME2:\n"; + echo " Specify a list of module-name to enable, in upper case, with MAIN_MODULE_ prefix, joined by comma.\n"; echo "\n"; echo "Options:\n"; echo " -c, --config :\n";