- Use clisetup.php where possible, remove redundant code

release-0.6
alecpl 14 years ago
parent 61517ce39d
commit 6cc3f5887d

@ -20,12 +20,9 @@
*/
if (php_sapi_name() != 'cli') {
die('Not on the "shell" (php-cli).');
}
define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
require INSTALL_PATH.'program/include/iniset.php';
require INSTALL_PATH.'program/include/clisetup.php';
// mapping for table name => primary key
$primary_keys = array(

@ -52,12 +52,9 @@
* - you are dealing with counterfeit header data.
*/
if (php_sapi_name() != 'cli') {
die("Not on the 'shell' (php-cli).\n");
}
define('INSTALL_PATH', realpath(dirname(__FILE__).'/..') . '/');
require INSTALL_PATH . 'program/include/iniset.php';
require INSTALL_PATH . 'program/include/clisetup.php';
if ($argc < 2) {
die("Usage: " . basename($argv[0]) . " encrypted-hdr-part [encrypted-hdr-part ...]\n");

@ -20,12 +20,9 @@
*/
if (php_sapi_name() != 'cli') {
die('Not on the "shell" (php-cli).');
}
define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
require INSTALL_PATH.'program/include/iniset.php';
require INSTALL_PATH.'program/include/clisetup.php';
/** callback function for schema dump **/
function print_schema($dump)

@ -19,12 +19,9 @@
*/
if (php_sapi_name() != 'cli') {
die('Not on the "shell" (php-cli).');
}
define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
require_once INSTALL_PATH . 'program/include/iniset.php';
require_once INSTALL_PATH . 'program/include/clisetup.php';
$target_dir = unslashify($_SERVER['argv'][1]);

@ -19,9 +19,6 @@
*/
if (php_sapi_name() != 'cli') {
die('Not on the "shell" (php-cli).');
}
define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
require_once INSTALL_PATH . 'program/include/clisetup.php';

Loading…
Cancel
Save