summaryrefslogtreecommitdiff
path: root/process_sql.php
diff options
context:
space:
mode:
authorlsces <lester@lsces.co.uk>2026-04-05 15:29:16 +0100
committerlsces <lester@lsces.co.uk>2026-04-05 15:29:16 +0100
commit516dfc95fcd3558e4dc205f2a2b87b44bf47c4a8 (patch)
tree4e5bff0c166142bcd0f1841a3ad6ff14bcd1c260 /process_sql.php
parenta285cd4a2b73315a874627faa9d28ddb538f26da (diff)
downloadinstall-516dfc95fcd3558e4dc205f2a2b87b44bf47c4a8.tar.gz
install-516dfc95fcd3558e4dc205f2a2b87b44bf47c4a8.tar.bz2
install-516dfc95fcd3558e4dc205f2a2b87b44bf47c4a8.zip
It does help if you stage changes from the right machine. This is the rework of the installer for namespace and php8.4
Diffstat (limited to 'process_sql.php')
-rwxr-xr-x[-rw-r--r--]process_sql.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/process_sql.php b/process_sql.php
index c7c5d73..cd08952 100644..100755
--- a/process_sql.php
+++ b/process_sql.php
@@ -9,7 +9,9 @@
* Global flag to indicate we are installing
* @ignore
*/
-define( 'BIT_INSTALL', 'TRUE' );
+
+namespace Bitweaver;
+define( 'BIT_INSTALL', 'true' );
global $failedcommands;
// keep some crappy notices from spewing
$_SERVER['HTTP_HOST'] = 'shell';
@@ -18,17 +20,15 @@ $_SERVER['SERVER_SOFTWARE'] = 'command_line';
/**
* required setup
*/
-require_once( 'install_lib.php' );
-include("../kernel/includes/setup_inc.php");
+require_once 'includes/install_lib.php';
+include '../kernel/includes/setup_inc.php';
if( count( $argv ) < 2) {
print "Please enter name of SQL file in db/ directory to process\n";
} else {
// avoid errors in ADONewConnection() (wrong darabase driver etc...)
- $gBitDb = &ADONewConnection($gBitDbType);
- if( $gBitDb->Connect($gBitDbHost, $gBitDbUser, $gBitDbPassword, $gBitDbName) ) {
+ $gBitDb = ADONewConnection($gBitDbType);
+ if( $gBitDb->Connect($gBitDbHost, $gBitDbUser, $gBitDbPassword, $gBitDbType != 'pdo' ? $gBitDbName : NULL ) ) {
process_sql_file( $argv[1], $gBitDbType, BIT_DB_PREFIX );
}
-}
-
-?>
+} \ No newline at end of file