~增加开机启动时的联网检测机制,以修复部分设备开机自启失败的问题

~尝试增加启动等待时长至10s
~将singbox内核DNS的默认reverse_mapping及independent_cache功能设置为false
~移除了wget命令的重试次数,以兼容更多设备
~修复部分脚本语法错误
This commit is contained in:
juewuy
2024-04-13 11:19:01 +08:00
parent 20c7212047
commit c5e28110cb
3 changed files with 26 additions and 13 deletions

View File

@@ -75,7 +75,7 @@ setrules(){ #自定义规则
'') ;;
*)
text=$(cat $YAMLSDIR/rules.yaml | grep -Ev '^#' | sed -n "$num p" | awk '{print $2}')
if [ -n $text ];then
if [ -n "$text" ];then
sed -i "/$text/d" $YAMLSDIR/rules.yaml
sleep 1
del_rule_type
@@ -676,7 +676,7 @@ setproviders(){ #自定义providers
[ "$res" = "1" ] && rm -rf $CRASHDIR/configs/providers.cfg
setproviders
;;
d)
e)
echo -e "\033[33m将清空 $CRASHDIR/providers 目录下所有内容\033[0m"
read -p "是否继续?(1/0) > " res
[ "$res" = "1" ] && rm -rf $CRASHDIR/providers
@@ -1651,7 +1651,7 @@ setcustgeo(){ #下载自定义数据库文件
}
setgeo(){ #数据库选择菜单
source $CFG_PATH > /dev/null
[ -n "$cn_mini.mmdb_v" ] && geo_type_des=精简版 || geo_type_des=全球版
[ -n "$cn_mini_v" ] && geo_type_des=精简版 || geo_type_des=全球版
echo -----------------------------------------------
echo -e "\033[36m请选择需要更新的Geo/CN数据库文件\033[0m"
echo -e "\033[36m全球版GeoIP和精简版CN-IP数据库不共存\033[0m"