新增适配 openKylin 开放麒麟操作系统

This commit is contained in:
Super Manito
2024-12-02 19:03:05 +08:00
parent 01c6afa4f6
commit 5dcdc2ba5a
9 changed files with 103 additions and 68 deletions

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
## Author: SuperManito ## Author: SuperManito
## Modified: 2024-11-14 ## Modified: 2024-12-02
## License: MIT ## License: MIT
## GitHub: https://github.com/SuperManito/LinuxMirrors ## GitHub: https://github.com/SuperManito/LinuxMirrors
## Website: https://linuxmirrors.cn ## Website: https://linuxmirrors.cn
@@ -170,6 +170,7 @@ SYSTEM_FEDORA="Fedora"
SYSTEM_OPENCLOUDOS="OpenCloudOS" SYSTEM_OPENCLOUDOS="OpenCloudOS"
SYSTEM_OPENEULER="openEuler" SYSTEM_OPENEULER="openEuler"
SYSTEM_ANOLISOS="Anolis OS" SYSTEM_ANOLISOS="Anolis OS"
SYSTEM_OPENKYLIN="openKylin"
SYSTEM_OPENSUSE="openSUSE" SYSTEM_OPENSUSE="openSUSE"
SYSTEM_ARCH="Arch" SYSTEM_ARCH="Arch"
SYSTEM_ALPINE="Alpine" SYSTEM_ALPINE="Alpine"
@@ -183,6 +184,7 @@ File_ArmbianRelease=/etc/armbian-release
File_OpenCloudOSRelease=/etc/opencloudos-release File_OpenCloudOSRelease=/etc/opencloudos-release
File_openEulerRelease=/etc/openEuler-release File_openEulerRelease=/etc/openEuler-release
File_AnolisOSRelease=/etc/anolis-release File_AnolisOSRelease=/etc/anolis-release
File_openKylinVersion=/etc/kylin-version/kylin-system-version.conf
File_ArchLinuxRelease=/etc/arch-release File_ArchLinuxRelease=/etc/arch-release
File_AlpineRelease=/etc/alpine-release File_AlpineRelease=/etc/alpine-release
File_GentooRelease=/etc/gentoo-release File_GentooRelease=/etc/gentoo-release
@@ -270,7 +272,7 @@ function handle_command_options() {
--branch-vault 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) 分支名 --branch-vault 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) 分支名
--branch-portage 指定 Gentoo 系统 portage 仓库的软件源分支(路径) 分支名 --branch-portage 指定 Gentoo 系统 portage 仓库的软件源分支(路径) 分支名
--branch-base-system 指定 Linux Mint 系统底层系统的软件源分支(路径) 分支名 --branch-base-system 指定 Linux Mint 系统底层系统的软件源分支(路径) 分支名
--codename 指定 Debian 系操作系统的版本代号 代号名称 --codename 指定 Debian 系/openKylin 操作系统的版本代号 代号名称
--protocol 指定 WEB 协议 http 或 https --protocol 指定 WEB 协议 http 或 https
--use-intranet-source 是否优先使用内网软件源地址 true 或 false --use-intranet-source 是否优先使用内网软件源地址 true 或 false
--use-official-source 是否使用目标操作系统的官方软件源 true 或 false --use-official-source 是否使用目标操作系统的官方软件源 true 或 false
@@ -632,20 +634,22 @@ function collect_system_info() {
## 判定当前系统派系 ## 判定当前系统派系
if [ -s $File_DebianVersion ]; then if [ -s $File_DebianVersion ]; then
SYSTEM_FACTIONS="${SYSTEM_DEBIAN}" SYSTEM_FACTIONS="${SYSTEM_DEBIAN}"
elif [ -s $File_RedHatRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_REDHAT}"
elif [ -s $File_OpenCloudOSRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENCLOUDOS}" # 注RedHat 判断优先级需要高于 OpenCloudOS自 9.0 版本起不再基于红帽
elif [ -s $File_openEulerRelease ]; then elif [ -s $File_openEulerRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENEULER}" SYSTEM_FACTIONS="${SYSTEM_OPENEULER}"
elif [ -s $File_AnolisOSRelease ]; then elif [ -s $File_AnolisOSRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_ANOLISOS}" SYSTEM_FACTIONS="${SYSTEM_ANOLISOS}"
elif [ -s $File_openKylinVersion ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENKYLIN}"
elif [ -f $File_ArchLinuxRelease ]; then elif [ -f $File_ArchLinuxRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_ARCH}" SYSTEM_FACTIONS="${SYSTEM_ARCH}"
elif [ -f $File_AlpineRelease ]; then elif [ -f $File_AlpineRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_ALPINE}" SYSTEM_FACTIONS="${SYSTEM_ALPINE}"
elif [ -f $File_GentooRelease ]; then elif [ -f $File_GentooRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_GENTOO}" SYSTEM_FACTIONS="${SYSTEM_GENTOO}"
elif [ -s $File_RedHatRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_REDHAT}"
elif [ -s $File_OpenCloudOSRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENCLOUDOS}" # 注RedHat 判断优先级需要高于 OpenCloudOS自 9.0 版本起不再基于红帽
elif [[ "${SYSTEM_NAME}" == *"openSUSE"* ]]; then elif [[ "${SYSTEM_NAME}" == *"openSUSE"* ]]; then
SYSTEM_FACTIONS="${SYSTEM_OPENSUSE}" SYSTEM_FACTIONS="${SYSTEM_OPENSUSE}"
else else
@@ -653,7 +657,7 @@ function collect_system_info() {
fi fi
## 判定系统类型、版本、版本号 ## 判定系统类型、版本、版本号
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
if [ ! -x /usr/bin/lsb_release ]; then if [ ! -x /usr/bin/lsb_release ]; then
apt-get install -y lsb-release apt-get install -y lsb-release
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
@@ -736,7 +740,7 @@ function collect_system_info() {
;; ;;
esac esac
;; ;;
"${SYSTEM_KALI}" | "${SYSTEM_DEEPIN}" | "${SYSTEM_ZORIN}" | "${SYSTEM_ARCH}" | "${SYSTEM_ALPINE}" | "${SYSTEM_GENTOO}") "${SYSTEM_KALI}" | "${SYSTEM_DEEPIN}" | "${SYSTEM_ZORIN}" | "${SYSTEM_ARCH}" | "${SYSTEM_ALPINE}" | "${SYSTEM_GENTOO}" | "${SYSTEM_OPENKYLIN}")
# 理论全部支持或不作判断 # 理论全部支持或不作判断
;; ;;
*) *)
@@ -834,7 +838,7 @@ function collect_system_info() {
fi fi
## 定义软件源更新文字 ## 定义软件源更新文字
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}" | "${SYSTEM_ALPINE}") "${SYSTEM_DEBIAN}" | "${SYSTEM_ALPINE}" | "${SYSTEM_OPENKYLIN}")
SYNC_MIRROR_TEXT="更新软件源" SYNC_MIRROR_TEXT="更新软件源"
;; ;;
"${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}") "${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}")
@@ -855,7 +859,7 @@ function check_command_options() {
output_error "两种模式不可同时使用!" output_error "两种模式不可同时使用!"
fi fi
if [[ "${DEBIAN_CODENAME}" ]]; then if [[ "${DEBIAN_CODENAME}" ]]; then
if [[ "${SYSTEM_FACTIONS}" != "${SYSTEM_DEBIAN}" ]]; then if [[ "${SYSTEM_FACTIONS}" != "${SYSTEM_DEBIAN}" && "${SYSTEM_FACTIONS}" != "${SYSTEM_OPENKYLIN}" ]]; then
output_error "当前系统不支持使用指定版本代号命令选项,请确认后重试!" output_error "当前系统不支持使用指定版本代号命令选项,请确认后重试!"
fi fi
fi fi
@@ -1216,7 +1220,7 @@ function backup_original_mirrors() {
BACKED_UP="false" # 是否已备份 BACKED_UP="false" # 是否已备份
if [[ "${BACKUP}" == "true" ]]; then if [[ "${BACKUP}" == "true" ]]; then
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then
# /etc/apt/sources.list # /etc/apt/sources.list
backup_file $File_DebianSourceList $File_DebianSourceListBackup "sources.list" backup_file $File_DebianSourceList $File_DebianSourceListBackup "sources.list"
@@ -1273,7 +1277,7 @@ function backup_original_mirrors() {
## 移除原有软件源 ## 移除原有软件源
function remove_original_mirrors() { function remove_original_mirrors() {
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then
[ -f $File_DebianSourceList ] && sed -i '1,$d' $File_DebianSourceList [ -f $File_DebianSourceList ] && sed -i '1,$d' $File_DebianSourceList
fi fi
@@ -1416,7 +1420,7 @@ function change_mirrors_main() {
if [[ -x /usr/bin/diff && "${BACKED_UP}" == "true" ]]; then if [[ -x /usr/bin/diff && "${BACKED_UP}" == "true" ]]; then
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then if [[ "${SYSTEM_JUDGMENT}" != "${SYSTEM_LINUX_MINT}" ]]; then
diff_file $File_DebianSourceListBackup $File_DebianSourceList diff_file $File_DebianSourceListBackup $File_DebianSourceList
fi fi
@@ -1482,6 +1486,9 @@ function change_mirrors_main() {
"${SYSTEM_GENTOO}") "${SYSTEM_GENTOO}")
change_mirrors_Gentoo change_mirrors_Gentoo
;; ;;
"${SYSTEM_OPENKYLIN}")
change_mirrors_openKylin
;;
esac esac
## 比较差异 ## 比较差异
if [[ "${PRINT_DIFF}" == "true" ]]; then if [[ "${PRINT_DIFF}" == "true" ]]; then
@@ -1490,7 +1497,7 @@ function change_mirrors_main() {
## 更新软件源 ## 更新软件源
echo -e "\n$WORKING 开始${SYNC_MIRROR_TEXT}...\n" echo -e "\n$WORKING 开始${SYNC_MIRROR_TEXT}...\n"
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
apt-get update apt-get update
;; ;;
"${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}") "${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}")
@@ -1549,7 +1556,7 @@ function upgrade_software() {
fi fi
## 调用系统命令 ## 调用系统命令
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
apt-get autoremove -y >/dev/null 2>&1 apt-get autoremove -y >/dev/null 2>&1
apt-get clean >/dev/null 2>&1 apt-get clean >/dev/null 2>&1
;; ;;
@@ -1601,7 +1608,7 @@ function upgrade_software() {
echo -e '' echo -e ''
## 调用系统命令 ## 调用系统命令
case "${SYSTEM_FACTIONS}" in case "${SYSTEM_FACTIONS}" in
"${SYSTEM_DEBIAN}") "${SYSTEM_DEBIAN}" | "${SYSTEM_OPENKYLIN}")
apt-get upgrade -y apt-get upgrade -y
;; ;;
"${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}") "${SYSTEM_REDHAT}" | "${SYSTEM_OPENCLOUDOS}" | "${SYSTEM_OPENEULER}" | "${SYSTEM_ANOLISOS}")
@@ -2172,6 +2179,28 @@ sync-uri = rsync://${SOURCE_PORTAGE:-"${SOURCE}"}/${SOURCE_PORTAGE_BRANCH:-"gent
auto-sync = yes" >$File_GentooReposConf auto-sync = yes" >$File_GentooReposConf
} }
## 更换 openKylin 发行版软件源
function change_mirrors_openKylin() {
function gen_source() {
echo "deb ${1} ${2} ${3}
# deb-src ${1} ${2} ${3}
deb ${1} ${2}-security ${3}
# deb-src ${1} ${2}-security ${3}
deb ${1} ${2}-updates ${3}
# deb-src ${1} ${2}-updates ${3}"
}
## 使用官方源
if [[ "${USE_OFFICIAL_SOURCE}" == "true" ]]; then
SOURCE="archive.build.openkylin.top"
fi
local repository_sections="main cross pty" # 仓库区域
local tips="## 默认禁用源码镜像以提高速度,如需启用请自行取消注释"
local base_url="${WEB_PROTOCOL}://${SOURCE}/${SOURCE_BRANCH}"
echo "${tips}
$(gen_source "${base_url}" "${SYSTEM_VERSION_CODENAME}" "${repository_sections}")" >>$File_DebianSourceList
}
## EPEL (Extra Packages for Enterprise Linux) 附加软件包 - 安装或更换软件源 ## EPEL (Extra Packages for Enterprise Linux) 附加软件包 - 安装或更换软件源
function change_mirrors_or_install_EPEL() { function change_mirrors_or_install_EPEL() {
if [[ "${INSTALL_EPEL}" != "true" ]]; then if [[ "${INSTALL_EPEL}" != "true" ]]; then

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
## Author: SuperManito ## Author: SuperManito
## Modified: 2024-11-02 ## Modified: 2024-12-02
## License: MIT ## License: MIT
## GitHub: https://github.com/SuperManito/LinuxMirrors ## GitHub: https://github.com/SuperManito/LinuxMirrors
## Website: https://linuxmirrors.cn ## Website: https://linuxmirrors.cn
@@ -273,10 +273,6 @@ function collect_system_info() {
## 判定当前系统派系 ## 判定当前系统派系
if [ -s $File_DebianVersion ]; then if [ -s $File_DebianVersion ]; then
SYSTEM_FACTIONS="${SYSTEM_DEBIAN}" SYSTEM_FACTIONS="${SYSTEM_DEBIAN}"
elif [ -s $File_openEulerRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENEULER}"
elif [ -s $File_AnolisOSRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_ANOLISOS}"
elif [ -s $File_RedHatRelease ]; then elif [ -s $File_RedHatRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_REDHAT}" SYSTEM_FACTIONS="${SYSTEM_REDHAT}"
elif [ -s $File_OpenCloudOSRelease ]; then elif [ -s $File_OpenCloudOSRelease ]; then
@@ -284,6 +280,10 @@ function collect_system_info() {
output_error "不支持当前操作系统,请参考如下命令自行安装:\n\ndnf install -y docker\nsystemctl enable --now docker" output_error "不支持当前操作系统,请参考如下命令自行安装:\n\ndnf install -y docker\nsystemctl enable --now docker"
fi fi
# SYSTEM_FACTIONS="${SYSTEM_OPENCLOUDOS}" # 注RedHat 判断优先级需要高于 OpenCloudOS自 9.0 版本起不再基于红帽 # SYSTEM_FACTIONS="${SYSTEM_OPENCLOUDOS}" # 注RedHat 判断优先级需要高于 OpenCloudOS自 9.0 版本起不再基于红帽
elif [ -s $File_openEulerRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_OPENEULER}"
elif [ -s $File_AnolisOSRelease ]; then
SYSTEM_FACTIONS="${SYSTEM_ANOLISOS}"
else else
output_error "无法判断当前运行环境或不支持当前操作系统!" output_error "无法判断当前运行环境或不支持当前操作系统!"
fi fi

View File

@@ -35,7 +35,7 @@
<td align="center">19 ~ 22 / LMDE 6</td> <td align="center">19 ~ 22 / LMDE 6</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.deepin.org" target="_blank"><img src="./docs/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.15em"></a>&nbsp;deepin</td> <td><a href="https://www.deepin.org" target="_blank"><img src="./docs/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.15em"></a>&nbsp;Deepin(深度)</td>
<td align="center">all</td> <td align="center">all</td>
</tr> </tr>
<tr> <tr>
@@ -71,17 +71,21 @@
<td align="center">8 ~ 9</td> <td align="center">8 ~ 9</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.opencloudos.org" target="_blank"><img src="./docs/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a>&nbsp;OpenCloudOS</td> <td><a href="https://www.opencloudos.org" target="_blank"><img src="./docs/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a>&nbsp;OpenCloudOS(鸥栖)</td>
<td align="center">8 ~ 9</td> <td align="center">8 ~ 9</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.openeuler.org/zh" target="_blank"><img src="./docs/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a>&nbsp;openEuler</td> <td><a href="https://www.openeuler.org/zh" target="_blank"><img src="./docs/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a>&nbsp;openEuler(开源欧拉)</td>
<td align="center">21 ~ 24</td> <td align="center">21 ~ 24</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://openanolis.cn" target="_blank"><img src="./docs/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a>&nbsp;Anolis OS</td> <td><a href="https://openanolis.cn" target="_blank"><img src="./docs/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a>&nbsp;Anolis OS(龙蜥)</td>
<td align="center">23</td> <td align="center">23</td>
</tr> </tr>
<tr>
<td><a href="https://www.openkylin.top" target="_blank"><img src="./docs/assets/images/icon/openkylin.ico" width="16" height="16" style="vertical-align: -0.25em"></a>&nbsp;openKylin开放麒麟</td>
<td align="center">all</td>
</tr>
<tr> <tr>
<td><a href="https://www.opensuse.org" target="_blank"><img src="./docs/assets/images/icon/opensuse.svg" width="16" height="16" style="vertical-align: -0.15em"></a>&nbsp;openSUSE</td> <td><a href="https://www.opensuse.org" target="_blank"><img src="./docs/assets/images/icon/opensuse.svg" width="16" height="16" style="vertical-align: -0.15em"></a>&nbsp;openSUSE</td>
<td align="center">Leep 15 / Tumbleweed</td> <td align="center">Leep 15 / Tumbleweed</td>
@@ -102,7 +106,7 @@
<p align="center"> <p align="center">
<strong> <strong>
<a href="https://linuxmirrors.cn/use" style="text-decoration: none;">使用方法</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://linuxmirrors.cn/mirrors" style="text-decoration: none;">软件源列表</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://linuxmirrors.cn/help" style="text-decoration: none;">常见问题</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://linuxmirrors.cn/other" style="text-decoration: none;">Docker 安装(额外脚本)</a> <a href="https://linuxmirrors.cn/use" style="text-decoration: none;">使用方法</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://linuxmirrors.cn/mirrors" style="text-decoration: none;">软件源列表</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://linuxmirrors.cn/other" style="text-decoration: none;">Docker 安装(额外脚本)</a>
</strong> </strong>
</p> </p>

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@@ -79,7 +79,7 @@ hide:
| <a href="https://cn.ubuntu.com" target="_blank"><img src="/assets/images/icon/ubuntu.svg" width="16" height="16" style="vertical-align: -0.1em"></a> Ubuntu :material-information-outline:{ title="支持乌班图家族衍生操作系统,例如 <code>优麒麟</code> <code>Kubuntu</code><br/>由于迭代速度较快并不直接支持所有非 LTS 的版本,具体详见使用文档中的高级用法" } | _14 ~ 24_ | | <a href="https://cn.ubuntu.com" target="_blank"><img src="/assets/images/icon/ubuntu.svg" width="16" height="16" style="vertical-align: -0.1em"></a> Ubuntu :material-information-outline:{ title="支持乌班图家族衍生操作系统,例如 <code>优麒麟</code> <code>Kubuntu</code><br/>由于迭代速度较快并不直接支持所有非 LTS 的版本,具体详见使用文档中的高级用法" } | _14 ~ 24_ |
| <a href="https://www.kali.org" target="_blank"><img src="/assets/images/icon/kali-linux.svg" width="16" height="16"></a> Kali Linux | _all_ | | <a href="https://www.kali.org" target="_blank"><img src="/assets/images/icon/kali-linux.svg" width="16" height="16"></a> Kali Linux | _all_ |
| <a href="https://linuxmint.com" target="_blank"><img src="/assets/images/icon/linux-mint.ico" width="16" height="16" style="vertical-align: -0.2em"></a> Linux Mint | _19 ~ 22 / LMDE 6_ | | <a href="https://linuxmint.com" target="_blank"><img src="/assets/images/icon/linux-mint.ico" width="16" height="16" style="vertical-align: -0.2em"></a> Linux Mint | _19 ~ 22 / LMDE 6_ |
| <a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.25em"></a> Deepin | _all_ | | <a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.25em"></a> Deepin(深度) | _all_ |
| <a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.15em"></a> Zorin OS | _all_ | | <a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.15em"></a> Zorin OS | _all_ |
| <a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian | _all_ | | <a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian | _all_ |
| <a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox | _all_ | | <a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox | _all_ |
@@ -88,9 +88,10 @@ hide:
| <a href="https://www.centos.org" target="_blank"><img src="/assets/images/icon/centos.svg" width="16" height="16" style="vertical-align: -0.2em"></a> CentOS | _7 ~ 8 / Stream 8 ~ 9_ | | <a href="https://www.centos.org" target="_blank"><img src="/assets/images/icon/centos.svg" width="16" height="16" style="vertical-align: -0.2em"></a> CentOS | _7 ~ 8 / Stream 8 ~ 9_ |
| <a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux | _8 ~ 9_ | | <a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux | _8 ~ 9_ |
| <a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux | _8 ~ 9_ | | <a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux | _8 ~ 9_ |
| <a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS | _8 ~ 9_ | | <a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS(鸥栖) | _8 ~ 9_ |
| <a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler | _21 ~ 24_ | | <a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler(开源欧拉) | _21 ~ 24_ |
| <a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS | _23_ | | <a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS(龙蜥) | _23_ |
| <a href="https://www.openkylin.top" target="_blank"><img src="/assets/images/icon/openkylin.ico" width="16" height="16" style="vertical-align: -0.25em"></a> openKylin开放麒麟 | _all_ |
| <a href="https://www.opensuse.org" target="_blank"><img src="/assets/images/icon/opensuse.svg" width="16" height="16"></a> openSUSE | _Leep 15 / Tumbleweed_ | | <a href="https://www.opensuse.org" target="_blank"><img src="/assets/images/icon/opensuse.svg" width="16" height="16"></a> openSUSE | _Leep 15 / Tumbleweed_ |
| <a href="https://archlinux.org" target="_blank"><img src="/assets/images/icon/arch-linux.ico" width="16" height="16" style="vertical-align: -0.15em"></a> Arch Linux | _all_ | | <a href="https://archlinux.org" target="_blank"><img src="/assets/images/icon/arch-linux.ico" width="16" height="16" style="vertical-align: -0.15em"></a> Arch Linux | _all_ |
| <a href="https://www.alpinelinux.org" target="_blank"><img src="/assets/images/icon/alpine.png" width="16" height="16" style="vertical-align: -0.15em"></a> Alpine Linux | _v3 / edge_ | | <a href="https://www.alpinelinux.org" target="_blank"><img src="/assets/images/icon/alpine.png" width="16" height="16" style="vertical-align: -0.15em"></a> Alpine Linux | _v3 / edge_ |

View File

@@ -10,22 +10,22 @@ hide:
> 下方列表中的镜像站均支持 `Debian` `Ubuntu` `CentOS` `openSUSE` `openEuler` 软件源,列表根据单位性质、地理位置、名称长度进行排序,与实际速度无关 > 下方列表中的镜像站均支持 `Debian` `Ubuntu` `CentOS` `openSUSE` `openEuler` 软件源,列表根据单位性质、地理位置、名称长度进行排序,与实际速度无关
| 镜像站 | IPv6 | Arch Linux | Kali Linux | Deepin | Rocky Linux | AlmaLinux | EPEL :material-information-outline:{ title="EPEL (Extra Packages for Enterprise Linux) 是由 Fedora 组织维护的一个附加软件包仓库,它主要适用于除 Fedora 操作系统以外的红帽系 Linux 发行版" } | Fedora | OpenCloudOS | Alpine Linux | Armbian | Proxmox | Linux Mint | Gentoo | Anolis OS | | 镜像站 | IPv6 | Arch Linux | Kali Linux | Deepin | Rocky Linux | AlmaLinux | EPEL :material-information-outline:{ title="EPEL (Extra Packages for Enterprise Linux) 是由 Fedora 组织维护的一个附加软件包仓库,它主要适用于除 Fedora 操作系统以外的红帽系 Linux 发行版" } | Fedora | OpenCloudOS | Alpine Linux | Armbian | Proxmox | Linux Mint | Gentoo | Anolis OS | openKylin |
| :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: | :--: |
| [阿里云](https://mirrors.aliyun.com "mirrors.aliyun.com") | :supported: | :supported: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | | [阿里云](https://mirrors.aliyun.com "mirrors.aliyun.com") | :supported: | :supported: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: |
| [腾讯云](https://mirrors.tencent.com "mirrors.tencent.com") | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | | [腾讯云](https://mirrors.tencent.com "mirrors.tencent.com") | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :unsupport: |
| [华为云](https://mirrors.huaweicloud.com "mirrors.huaweicloud.com") | :unsupport: | :supported: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | | [华为云](https://mirrors.huaweicloud.com "mirrors.huaweicloud.com") | :unsupport: | :supported: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :unsupport: |
| [网易](https://mirrors.163.com "mirrors.163.com") | :unsupport: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | | [网易](https://mirrors.163.com "mirrors.163.com") | :unsupport: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: |
| [火山引擎](https://developer.volcengine.com/mirror "mirrors.volces.com") | :unsupport: | :unsupport: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | | [火山引擎](https://developer.volcengine.com/mirror "mirrors.volces.com") | :unsupport: | :unsupport: | :supported: | :supported: | :incompatible: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: |
| [清华大学](https://mirrors.tuna.tsinghua.edu.cn "mirrors.tuna.tsinghua.edu.cn") | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | | [清华大学](https://mirrors.tuna.tsinghua.edu.cn "mirrors.tuna.tsinghua.edu.cn") | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: |
| [北京大学](https://mirrors.pku.edu.cn/Mirrors "mirrors.pku.edu.cn") | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :unsupport: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | | [北京大学](https://mirrors.pku.edu.cn/Mirrors "mirrors.pku.edu.cn") | :supported: | :supported: | :unsupport: | :unsupport: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: | :unsupport: |
| [浙江大学](https://mirrors.zju.edu.cn "mirrors.zju.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :supported: | | [浙江大学](https://mirrors.zju.edu.cn "mirrors.zju.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :supported: | :unsupport: |
| [南京大学](https://mirrors.nju.edu.cn "mirrors.nju.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | | [南京大学](https://mirrors.nju.edu.cn "mirrors.nju.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: |
| [兰州大学](https://mirror.lzu.edu.cn "mirror.lzu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | | [兰州大学](https://mirror.lzu.edu.cn "mirror.lzu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :unsupport: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: |
| [上海交通大学](https://mirror.sjtu.edu.cn "mirror.sjtu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :incompatible: | :incompatible: | :supported: | :incompatible: | :supported: | :unsupport: | :supported: | :incompatible: | :unsupport: | | [上海交通大学](https://mirror.sjtu.edu.cn "mirror.sjtu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :incompatible: | :incompatible: | :supported: | :incompatible: | :supported: | :unsupport: | :supported: | :incompatible: | :unsupport: | :supported: |
| [重庆邮电大学](https://mirrors.cqupt.edu.cn "mirrors.cqu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :unsupport: | | [重庆邮电大学](https://mirrors.cqupt.edu.cn "mirrors.cqu.edu.cn") | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: | :unsupport: | :unsupport: |
| [中国科学技术大学](https://mirrors.ustc.edu.cn "mirrors.ustc.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | | [中国科学技术大学](https://mirrors.ustc.edu.cn "mirrors.ustc.edu.cn") | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :unsupport: |
| [中国科学院软件研究所](https://mirror.iscas.ac.cn "mirror.iscas.ac.cn") | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | | [中国科学院软件研究所](https://mirror.iscas.ac.cn "mirror.iscas.ac.cn") | :unsupport: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :supported: | :unsupport: | :supported: |
???+ question "使用帮助" ???+ question "使用帮助"

View File

@@ -30,20 +30,20 @@ hide:
<td><a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux</td> <td><a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.3em"></a> Deepin</td> <td><a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.3em"></a> Deepin(深度)</td>
<td><a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux</td> <td><a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.3em"></a> Zorin OS</td> <td><a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.3em"></a> Zorin OS</td>
<td><a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS</td> <td><a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS(鸥栖)</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian</td> <td><a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian</td>
<td><a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler</td> <td><a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler(开源欧拉)</td>
</tr> </tr>
<tr> <tr>
<td><a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox</td> <td><a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox</td>
<td><a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS</td> <td><a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS(龙蜥)</td>
</tr> </tr>
</table> </table>

View File

@@ -118,13 +118,13 @@ hide:
!!! quote "" !!! quote ""
=== "Debian 系" === "Debian 系 / openKylin"
``` sh ``` sh
apt-get install -y curl apt-get install -y curl
``` ```
> `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` > `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` &nbsp; `openKylin`
新装系统需要先执行一遍更新 `apt-get update` 新装系统需要先执行一遍更新 `apt-get update`
@@ -195,14 +195,14 @@ hide:
!!! quote "" !!! quote ""
=== "Debian 系" === "Debian 系 / openKylin"
``` sh ``` sh
cp -rf /etc/apt/sources.list.bak /etc/apt/sources.list cp -rf /etc/apt/sources.list.bak /etc/apt/sources.list
apt-get update apt-get update
``` ```
> `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` > `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` &nbsp; `openKylin`
=== "RedHat 系 / OpenCloudOS / openEuler / Anolis OS" === "RedHat 系 / OpenCloudOS / openEuler / Anolis OS"
@@ -258,11 +258,11 @@ hide:
脚本遵循系统默认设置即没有启用的软件源(仓库)不会在运行完本脚本后被启用,但是它们也随脚本更换了目标软件源地址,如果你有使用需求请阅读下面的启用方法 脚本遵循系统默认设置即没有启用的软件源(仓库)不会在运行完本脚本后被启用,但是它们也随脚本更换了目标软件源地址,如果你有使用需求请阅读下面的启用方法
=== "Debian 系" === "Debian 系 / openKylin"
默认禁用了`deb-src`源码仓库和`proposed`预发布软件源,若需启用请将 `/etc/apt/sources.list` 文件中相关内容的所在行取消注释 默认禁用了`deb-src`源码仓库和`proposed`预发布软件源,若需启用请将 `/etc/apt/sources.list` 文件中相关内容的所在行取消注释
> `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` > `Debian` &nbsp; `Ubuntu` &nbsp; `Kali` &nbsp; `Linux Mint` &nbsp; `Deepin` &nbsp; `Zorin OS` &nbsp; `Armbian` &nbsp; `Proxmox` &nbsp; `openKylin`
=== "RedHat 系 / OpenCloudOS / openEuler / Anolis OS" === "RedHat 系 / OpenCloudOS / openEuler / Anolis OS"
@@ -295,7 +295,7 @@ hide:
| `--branch-vault` | 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) | `分支名` | | `--branch-vault` | 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) | `分支名` |
| `--branch-portage` | 指定 Gentoo 系统 portage 仓库的软件源分支(路径) | `分支名` | | `--branch-portage` | 指定 Gentoo 系统 portage 仓库的软件源分支(路径) | `分支名` |
| `--branch-base-system` | 指定 Linux Mint 系统底层系统的软件源分支(路径) | `分支名` | | `--branch-base-system` | 指定 Linux Mint 系统底层系统的软件源分支(路径) | `分支名` |
| `--codename` | 指定 Debian 系操作系统的版本代号 | `代号名称` | | `--codename` | 指定 Debian 系 / openKylin 操作系统的版本代号 | `代号名称` |
| `--protocol` | 指定 WEB 协议 | `http` 或 `https` | | `--protocol` | 指定 WEB 协议 | `http` 或 `https` |
| `--use-intranet-source` | 是否优先使用内网软件源地址 | `true` 或 `false` | | `--use-intranet-source` | 是否优先使用内网软件源地址 | `true` 或 `false` |
| `--use-official-source` | 是否使用目标操作系统的官方软件源 | `true` 或 `false` | | `--use-official-source` | 是否使用目标操作系统的官方软件源 | `true` 或 `false` |
@@ -334,7 +334,7 @@ hide:
| <a href="https://cn.ubuntu.com" target="_blank"><img src="/assets/images/icon/ubuntu.svg" width="16" height="16" style="vertical-align: -0.1em"></a> Ubuntu | ubuntu / ubuntu-ports | | <a href="https://cn.ubuntu.com" target="_blank"><img src="/assets/images/icon/ubuntu.svg" width="16" height="16" style="vertical-align: -0.1em"></a> Ubuntu | ubuntu / ubuntu-ports |
| <a href="https://www.kali.org" target="_blank"><img src="/assets/images/icon/kali-linux.svg" width="16" height="16"></a> Kali Linux | kali | | <a href="https://www.kali.org" target="_blank"><img src="/assets/images/icon/kali-linux.svg" width="16" height="16"></a> Kali Linux | kali |
| <a href="https://linuxmint.com" target="_blank"><img src="/assets/images/icon/linux-mint.ico" width="16" height="16" style="vertical-align: -0.2em"></a> Linux Mint | linuxmint / ubuntu / ubuntu-ports / debian | | <a href="https://linuxmint.com" target="_blank"><img src="/assets/images/icon/linux-mint.ico" width="16" height="16" style="vertical-align: -0.2em"></a> Linux Mint | linuxmint / ubuntu / ubuntu-ports / debian |
| <a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.25em"></a> Deepin | deepin | | <a href="https://www.deepin.org" target="_blank"><img src="/assets/images/icon/deepin.png" width="16" height="16" style="vertical-align: -0.25em"></a> Deepin(深度) | deepin |
| <a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.15em"></a> Zorin OS | ubuntu / ubuntu-ports | | <a href="https://zorin.com/os" target="_blank"><img src="/assets/images/icon/zorin-os.png" width="16" height="16" style="vertical-align: -0.15em"></a> Zorin OS | ubuntu / ubuntu-ports |
| <a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian | armbian | | <a href="https://www.armbian.com" target="_blank"><img src="/assets/images/icon/armbian.png" width="16" height="16" style="vertical-align: -0.2em"></a> Armbian | armbian |
| <a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox | proxmox | | <a href="https://www.proxmox.com" target="_blank"><img src="/assets/images/icon/proxmox.svg" width="16" height="16" style="vertical-align: -0.2em"></a> Proxmox | proxmox |
@@ -343,9 +343,10 @@ hide:
| <a href="https://www.centos.org" target="_blank"><img src="/assets/images/icon/centos.svg" width="16" height="16" style="vertical-align: -0.2em"></a> CentOS | centos / centos-stream / centos-altarch / centos-vault | | <a href="https://www.centos.org" target="_blank"><img src="/assets/images/icon/centos.svg" width="16" height="16" style="vertical-align: -0.2em"></a> CentOS | centos / centos-stream / centos-altarch / centos-vault |
| <a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux | rocky | | <a href="https://rockylinux.org" target="_blank"><img src="/assets/images/icon/rocky-linux.svg" width="16" height="16" style="vertical-align: -0.25em"></a> Rocky Linux | rocky |
| <a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux | almalinux / almalinux-vault | | <a href="https://almalinux.org/zh-hans" target="_blank"><img src="/assets/images/icon/almalinux.svg" width="16" height="16" style="vertical-align: -0.15em"></a> AlmaLinux | almalinux / almalinux-vault |
| <a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS | opencloudos | | <a href="https://www.opencloudos.org" target="_blank"><img src="/assets/images/icon/opencloudos.png" width="16" height="16" style="vertical-align: -0.25em"></a> OpenCloudOS(鸥栖) | opencloudos |
| <a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler | openeuler | | <a href="https://www.openeuler.org/zh" target="_blank"><img src="/assets/images/icon/openeuler.ico" width="16" height="16" style="vertical-align: -0.2em"></a> openEuler(开源欧拉) | openeuler |
| <a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS | anolis | | <a href="https://openanolis.cn" target="_blank"><img src="/assets/images/icon/anolis.png" width="16" height="16" style="vertical-align: -0.1em"></a> Anolis OS(龙蜥) | anolis |
| <a href="https://www.openkylin.top" target="_blank"><img src="/assets/images/icon/openkylin.ico" width="16" height="16" style="vertical-align: -0.25em"></a> openKylin开放麒麟 | openkylin |
| <a href="https://www.opensuse.org" target="_blank"><img src="/assets/images/icon/opensuse.svg" width="16" height="16"></a> openSUSE | opensuse | | <a href="https://www.opensuse.org" target="_blank"><img src="/assets/images/icon/opensuse.svg" width="16" height="16"></a> openSUSE | opensuse |
| <a href="https://archlinux.org" target="_blank"><img src="/assets/images/icon/arch-linux.ico" width="16" height="16" style="vertical-align: -0.15em"></a> Arch Linux | archlinux / archlinuxarm | | <a href="https://archlinux.org" target="_blank"><img src="/assets/images/icon/arch-linux.ico" width="16" height="16" style="vertical-align: -0.15em"></a> Arch Linux | archlinux / archlinuxarm |
| <a href="https://www.alpinelinux.org" target="_blank"><img src="/assets/images/icon/alpine.png" width="16" height="16" style="vertical-align: -0.15em"></a> Alpine Linux | alpine | | <a href="https://www.alpinelinux.org" target="_blank"><img src="/assets/images/icon/alpine.png" width="16" height="16" style="vertical-align: -0.15em"></a> Alpine Linux | alpine |
@@ -450,11 +451,11 @@ hide:
## 定制脚本 ## 定制脚本
如果你是其它项目的开发者希望通过本项目来制作专属脚本,可以在克隆仓库后查看脚本头部注释,目前已经有国内教育单位镜像站的维护者这样做了,下面具体介绍一下定制方法。 如果你是其它项目的开发者希望通过本项目来制作专属脚本,目前已经有国内教育单位镜像站的维护者这样做了,下面简单介绍一下具体定制方法。
首先不建议修改代码的底层逻辑,应尽量与本项目源码保持同步,不过你可以简单去除一些无关内容,例如你可以将三个软件源列表(数组)中的内容删除 `mirror_list_default=()`。 1. 首先不建议修改代码的底层逻辑,应尽量与本项目源码保持同步,脚本内容执行顺序由 `main` 函数控制,代码逻辑清晰
2. 你可以简单去除一些无关内容,例如将三个软件源列表(数组)中的内容删除 `mirror_list_default=()`
相关脚本功能配置是由统一的变量控制的,命令选项亦是如此,这些全局变量由全大写字母构成并遵循下划线命名法,你只需要将这些变量声明在脚本头部即可快速完成定制,具体变量详见如下表格: 3. 脚本主要功能配置是由统一的变量控制的,命令选项亦是如此,这些全局变量由全大写字母构成并遵循下划线命名法,具体变量详见如下表格,你只需要将这些变量声明在脚本头部(预留注释区域)即可快速完成定制
| 变量名 | 含义 | 值类型 | | 变量名 | 含义 | 值类型 |
| :-: | :-: | :-: | | :-: | :-: | :-: |
@@ -470,7 +471,7 @@ hide:
| `SOURCE_VAULT_BRANCH` | 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) | `分支名` | | `SOURCE_VAULT_BRANCH` | 指定 CentOS/AlmaLinux 系统 vault 仓库的软件源分支(路径) | `分支名` |
| `SOURCE_PORTAGE_BRANCH` | 指定 Gentoo 系统 portage 仓库的软件源分支(路径) | `分支名` | | `SOURCE_PORTAGE_BRANCH` | 指定 Gentoo 系统 portage 仓库的软件源分支(路径) | `分支名` |
| `SOURCE_BASE_SYSTEM_BRANCH` | 指定 Linux Mint 系统底层系统的软件源分支(路径) | `分支名` | | `SOURCE_BASE_SYSTEM_BRANCH` | 指定 Linux Mint 系统底层系统的软件源分支(路径) | `分支名` |
| `DEBIAN_CODENAME` | 指定 Debian 系操作系统的版本代号 | `代号名称` | | `DEBIAN_CODENAME` | 指定 Debian 系 / openKylin 操作系统的版本代号 | `代号名称` |
| `USE_OFFICIAL_SOURCE` | 是否使用目标操作系统的官方软件源 | `true` 或 `false` | | `USE_OFFICIAL_SOURCE` | 是否使用目标操作系统的官方软件源 | `true` 或 `false` |
| `USE_INTRANET_SOURCE` | 是否优先使用内网软件源地址 | `true` 或 `false` | | `USE_INTRANET_SOURCE` | 是否优先使用内网软件源地址 | `true` 或 `false` |
| `WEB_PROTOCOL` | 指定 WEB 协议 | `http` 或 `https` | | `WEB_PROTOCOL` | 指定 WEB 协议 | `http` 或 `https` |
@@ -483,4 +484,4 @@ hide:
| `CLEAN_CACHE` | 是否清理下载缓存 | `true` 或 `false` | | `CLEAN_CACHE` | 是否清理下载缓存 | `true` 或 `false` |
| `PRINT_DIFF` | 是否打印源文件修改前后差异 | `true` 或 `false` | | `PRINT_DIFF` | 是否打印源文件修改前后差异 | `true` 或 `false` |
> 部分变量存在默认值,另外如果对应功能配置不存在那么就可能会出现交互 > 部分变量存在默认值,未涉及的变量无需声明为空值(空字符串),另外如果对应功能配置不存在那么就可能会出现交互

View File

@@ -1,3 +1,3 @@
mkdocs-material==9.5.44 mkdocs-material==9.5.47
mkdocs-glightbox==0.4.0 mkdocs-glightbox==0.4.0
mkdocs-exclude-search==0.6.6 mkdocs-exclude-search==0.6.6