diff --git a/.DS_Store b/.DS_Store index c5848fe..6257239 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/root/.DS_Store b/root/.DS_Store index 6b13736..118e5b5 100644 Binary files a/root/.DS_Store and b/root/.DS_Store differ diff --git a/root/etc/.DS_Store b/root/etc/.DS_Store index e3fc4b2..c7e020e 100644 Binary files a/root/etc/.DS_Store and b/root/etc/.DS_Store differ diff --git a/root/etc/mosdns/library.sh b/root/etc/mosdns/library.sh index 065ba2e..8492050 100755 --- a/root/etc/mosdns/library.sh +++ b/root/etc/mosdns/library.sh @@ -12,6 +12,14 @@ exist() { } getdat() { + if exist curl; then + curl -fSLo "$TMPDIR/$1" "https://ghproxy.com/https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/$1" + else + wget "https://ghproxy.com/https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/$1" -nv -O "$TMPDIR/$1" + fi +} + +get_ADlist() { if exist curl; then curl -fSLo "$TMPDIR/$1" "https://raw.cooluc.com/QiuSimons/openwrt-mos/master/dat/$1" else diff --git a/root/etc/mosdns/mosupdater.sh b/root/etc/mosdns/mosupdater.sh index c796220..fe8e4a5 100755 --- a/root/etc/mosdns/mosupdater.sh +++ b/root/etc/mosdns/mosupdater.sh @@ -20,7 +20,7 @@ syncconfig=$(uci -q get mosdns.mosdns.syncconfig) if [ "$syncconfig" -eq 1 ]; then TMPDIR=$(mktemp -d) || exit 2 get_config def_config.yaml - getdat serverlist.txt + get_ADlist serverlist.txt if [ "$(grep -o .com "$TMPDIR"/serverlist.txt | wc -l)" -lt "1000" ]; then rm -rf "$TMPDIR"/serverlist.txt