mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-07 00:35:41 +08:00
Enhance Linux distribution detection and package installation commands (forward-port #1109)
This commit is contained in:
@@ -50,6 +50,7 @@ class LinuxUtil extends UnixUtil
|
||||
|
||||
$ret['dist'] = trim($ret['dist'], '"\'');
|
||||
$ret['ver'] = trim($ret['ver'], '"\'');
|
||||
$ret['family'] = trim($ret['family'], '"\'');
|
||||
|
||||
if (strcasecmp($ret['dist'], 'centos') === 0) {
|
||||
$ret['dist'] = 'redhat';
|
||||
@@ -91,7 +92,7 @@ class LinuxUtil extends UnixUtil
|
||||
{
|
||||
return [
|
||||
// debian-like
|
||||
'debian', 'ubuntu', 'Deepin', 'neon',
|
||||
'debian', 'ubuntu', 'Deepin',
|
||||
// rhel-like
|
||||
'redhat',
|
||||
// centos
|
||||
|
||||
Reference in New Issue
Block a user