From cb653ebffb288fda5a9bfcf6ca8264096c975297 Mon Sep 17 00:00:00 2001 From: wukongdaily <2666180@gmail.com> Date: Wed, 13 Nov 2024 12:27:41 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=84=9A=E6=9C=AC=E5=8D=A1?= =?UTF-8?q?=E4=BD=8F=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gl-inet.sh | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/gl-inet.sh b/gl-inet.sh index 5dc6d49..4aa7277 100755 --- a/gl-inet.sh +++ b/gl-inet.sh @@ -40,16 +40,18 @@ install_istore_os_style() { is-opkg install 'app-meta-ddnsto' # 安装磁盘管理 is-opkg install 'app-meta-diskman' - # 若已安装iStore商店则在概览中追加iStore字样 - if ! grep -q " like iStoreOS" /tmp/sysinfo/model; then - sed -i '1s/$/ like iStoreOS/' /tmp/sysinfo/model - fi + FILE_PATH="/etc/openwrt_release" + NEW_DESCRIPTION="Openwrt like iStoreOS Style by wukongdaily" + CONTENT=$(cat $FILE_PATH) + UPDATED_CONTENT=$(echo "$CONTENT" | sed "s/DISTRIB_DESCRIPTION='[^']*'/DISTRIB_DESCRIPTION='$NEW_DESCRIPTION'/") + echo "$UPDATED_CONTENT" >$FILE_PATH } # 安装iStore 参考 https://github.com/linkease/istore do_istore() { echo "do_istore method==================>" - ISTORE_REPO=https://istore.linkease.com/repo/all/store + # 换源 + ISTORE_REPO=https://istore.istoreos.com/repo/all/store FCURL="curl --fail --show-error" curl -V >/dev/null 2>&1 || { @@ -73,6 +75,10 @@ do_istore() { /tmp/is-opkg opkg install --force-reinstall luci-app-store || exit $? [ -s "/etc/init.d/tasks" ] || /tmp/is-opkg opkg install --force-reinstall taskd [ -s "/usr/lib/lua/luci/cbi.lua" ] || /tmp/is-opkg opkg install luci-compat >/dev/null 2>&1 + # 换源 + sed -i 's/istore.linkease.com/istore.istoreos.com/g' /bin/is-opkg + sed -i 's/istore.linkease.com/istore.istoreos.com/g' /etc/opkg/compatfeeds.conf + sed -i 's/istore.linkease.com/istore.istoreos.com/g' /www/luci-static/istore/index.js } #设置风扇工作温度 @@ -472,7 +478,7 @@ do_install_docker_compose() { } #mt3000更换分区 -mt3000_overlay_changed(){ +mt3000_overlay_changed() { wget -O mt3000.sh "https://cafe.cpolar.cn/wkdaily/gl-inet-onescript/raw/branch/master/mt-3000/mt3000.sh" && chmod +x mt3000.sh sh mt3000.sh }