Skip to content

Commit

Permalink
Merge pull request civicrm#30997 from totten/master-nfc-install
Browse files Browse the repository at this point in the history
(NFC) Drop old comments about old installer
  • Loading branch information
totten authored Aug 28, 2024
2 parents 33048b5 + 9aa9bb5 commit 17894a4
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 46 deletions.
4 changes: 0 additions & 4 deletions CRM/Upgrade/Incremental/General.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ class CRM_Upgrade_Incremental_General {

/**
* The minimum PHP version required to install Civi.
*
* @see install/index.php
*/
const MIN_INSTALL_PHP_VER = '7.4.0';

Expand All @@ -53,8 +51,6 @@ class CRM_Upgrade_Incremental_General {

/**
* The minimum MySQL version required to install Civi.
*
* @see install/index.php
*/
const MIN_INSTALL_MYSQL_VER = '5.7';

Expand Down
42 changes: 0 additions & 42 deletions setup/src/Setup/DrupalUtil.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,49 +26,7 @@ public static function getDrupalSiteDir($cmsPath) {
throw new \Exception('Cannot detect path under Drupal "sites/".');
// The old 'install/index.php' system duplicated the conf_path() logic so that it could work pre-boot.
// With civicrm-setup, the CMS should always be booted first, so we should never go down this path.
// For the moment, the code is kept below in case it turns out we do need this for some reason.
}

/*
static $siteDir = '';
if ($siteDir) {
return $siteDir;
}
// The SCRIPT_FILENAME check was copied over from the 'install/index.php' system.
// It probably doesn't make sense in the context of civicrm-setup b/c we don't know what the SCRIPT will be
// and instead rely on $model inputs.
$sites = DIRECTORY_SEPARATOR . 'sites' . DIRECTORY_SEPARATOR;
$modules = DIRECTORY_SEPARATOR . 'modules' . DIRECTORY_SEPARATOR;
preg_match("/" . preg_quote($sites, DIRECTORY_SEPARATOR) .
"([\-a-zA-Z0-9_.]+)" .
preg_quote($modules, DIRECTORY_SEPARATOR) . "/",
$_SERVER['SCRIPT_FILENAME'], $matches
);
$siteDir = $matches[1] ?? 'default';
if (strtolower($siteDir) == 'all') {
// For this case - use drupal's way of finding out multi-site directory
$uri = explode(DIRECTORY_SEPARATOR, $_SERVER['SCRIPT_FILENAME']);
$server = explode('.', implode('.', array_reverse(explode(':', rtrim($_SERVER['HTTP_HOST'], '.')))));
for ($i = count($uri) - 1; $i > 0; $i--) {
for ($j = count($server); $j > 0; $j--) {
$dir = implode('.', array_slice($server, -$j)) . implode('.', array_slice($uri, 0, $i));
if (file_exists($cmsPath . DIRECTORY_SEPARATOR .
'sites' . DIRECTORY_SEPARATOR . $dir
)) {
$siteDir = $dir;
return $siteDir;
}
}
}
$siteDir = 'default';
}
return $siteDir;
*/
}

/**
Expand Down

0 comments on commit 17894a4

Please sign in to comment.