This commit is contained in:
spiritysdx
2024-07-04 12:59:36 +08:00
parent 226f751655
commit acebe04732
3 changed files with 5 additions and 5 deletions

View File

@@ -18,7 +18,7 @@ Shell版本 https://github.com/spiritLHLS/ecs
已支持的系统: Linux、Windows
待支持的系统(存在硬件测试BUG未修复): MacOS
待支持的系统(存在硬件测试BUG未修复): MacOS、Alpine
## 功能

View File

@@ -18,7 +18,7 @@ Pending support (due to unsupported dependencies): s390x
Supported systems: Linux, Windows
Pending support (due to unresolved hardware testing bugs): MacOS
Pending support (due to unresolved hardware testing bugs): MacOS、Alpine
## Features

View File

@@ -233,7 +233,9 @@ env_check() {
PACKAGE_INSTALL=("apt-get -y install" "apt-get -y install" "yum -y install" "yum -y install" "yum -y install" "pacman -Sy --noconfirm --needed" "pkg install -y" "apk add")
PACKAGE_REMOVE=("apt-get -y remove" "apt-get -y remove" "yum -y remove" "yum -y remove" "yum -y remove" "pacman -Rsc --noconfirm" "pkg delete" "apk del")
PACKAGE_UNINSTALL=("apt-get -y autoremove" "apt-get -y autoremove" "yum -y autoremove" "yum -y autoremove" "yum -y autoremove" "" "pkg autoremove" "apk autoremove")
if [ -s /etc/os-release ]; then
if [ -f /etc/alpine-release ]; then
SYS="alpine"
elif [ -s /etc/os-release ]; then
SYS="$(grep -i pretty_name /etc/os-release | cut -d \" -f2)"
elif [ -x "$(type -p hostnamectl)" ]; then
SYS="$(hostnamectl | grep -i system | cut -d : -f2)"
@@ -245,8 +247,6 @@ env_check() {
SYS="$(grep . /etc/redhat-release)"
elif [ -s /etc/issue ]; then
SYS="$(grep . /etc/issue | cut -d '\' -f1 | sed '/^[ ]*$/d')"
elif [ -f /etc/alpine-release ]; then
SYS="alpine"
else
SYS="$(uname -s)}"
fi