mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-09 13:06:14 +00:00
set logger and add option to turn it off again
This commit is contained in:
parent
38ac4e6005
commit
c8ec7d70f0
|
@ -18,12 +18,13 @@ function usage() { /* {{{ */
|
||||||
echo " -h, --help: print usage information and exit.".PHP_EOL;
|
echo " -h, --help: print usage information and exit.".PHP_EOL;
|
||||||
echo " -v, --version: print version and exit.".PHP_EOL;
|
echo " -v, --version: print version and exit.".PHP_EOL;
|
||||||
echo " -c: recreate index.".PHP_EOL;
|
echo " -c: recreate index.".PHP_EOL;
|
||||||
|
echo " --no-log: do not log.".PHP_EOL;
|
||||||
echo " --config: set alternative config file.".PHP_EOL;
|
echo " --config: set alternative config file.".PHP_EOL;
|
||||||
} /* }}} */
|
} /* }}} */
|
||||||
|
|
||||||
$version = "0.0.2";
|
$version = "0.0.3";
|
||||||
$shortoptions = "hvc";
|
$shortoptions = "hvc";
|
||||||
$longoptions = array('help', 'version', 'config:');
|
$longoptions = array('help', 'version', 'config:', 'no-log');
|
||||||
if(false === ($options = getopt($shortoptions, $longoptions))) {
|
if(false === ($options = getopt($shortoptions, $longoptions))) {
|
||||||
usage();
|
usage();
|
||||||
exit(0);
|
exit(0);
|
||||||
|
@ -55,6 +56,8 @@ if(isset($options['c'])) {
|
||||||
}
|
}
|
||||||
|
|
||||||
include($myincpath."/inc/inc.Settings.php");
|
include($myincpath."/inc/inc.Settings.php");
|
||||||
|
if(empty($options['no-log']))
|
||||||
|
include($myincpath."/inc/inc.LogInit.php");
|
||||||
include($myincpath."/inc/inc.Init.php");
|
include($myincpath."/inc/inc.Init.php");
|
||||||
include($myincpath."/inc/inc.Extension.php");
|
include($myincpath."/inc/inc.Extension.php");
|
||||||
include($myincpath."/inc/inc.DBInit.php");
|
include($myincpath."/inc/inc.DBInit.php");
|
||||||
|
|
Loading…
Reference in New Issue
Block a user