From 111fcb00e06cd8796137e30c35f58ca736353fe2 Mon Sep 17 00:00:00 2001 From: bin456789 Date: Thu, 14 Sep 2023 21:54:04 +0800 Subject: [PATCH] =?UTF-8?q?core:=20=E5=9B=BD=E5=86=85=E4=BD=BF=E7=94=A8=20?= =?UTF-8?q?gitee?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- reinstall.sh | 17 +++++------------ 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 27f7cad..0436a6f 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ curl -O https://raw.githubusercontent.com/bin456789/reinstall/main/reinstall.sh ### 下载 (国内): - curl -O https://ghproxy.com/https://raw.githubusercontent.com/bin456789/reinstall/main/reinstall.sh + curl -O https://gitee.com/bin456789/reinstall/raw/main/reinstall.sh ### 安装 Linux: bash reinstall.sh centos 7|8|9 (8|9 为 stream 版本) diff --git a/reinstall.sh b/reinstall.sh index 3c6ed54..836848b 100644 --- a/reinstall.sh +++ b/reinstall.sh @@ -116,16 +116,6 @@ get_host_by_url() { cut -d/ -f3 <<<$1 } -set_github_proxy() { - case "$confhome" in - http*://raw.githubusercontent.com/*) - if is_in_china; then - confhome=https://ghproxy.com/$confhome - fi - ;; - esac -} - test_url() { url=$1 expect_type=$2 @@ -845,8 +835,11 @@ case "$basearch" in "aarch64") basearch_alt=arm64 ;; esac -# 设置 github 国内代理 -set_github_proxy +# 国内使用 gitee +if [ "$confhome" = https://raw.githubusercontent.com/bin456789/reinstall/main ] && + is_in_china; then + confhome=https://gitee.com/bin456789/reinstall/raw/main +fi # 以下目标系统不需要进入alpine # debian