install.sh: openwrt-18.06 is no longer supported
Signed-off-by: sbwml <admin@cooluc.com>
This commit is contained in:
parent
83b3707716
commit
6f37807cf5
@ -24,10 +24,10 @@
|
|||||||
|
|
||||||
- Openwrt official SnapShots
|
- Openwrt official SnapShots
|
||||||
|
|
||||||
* requires golang 1.20.x or latest version (openwrt-21.02 & older version needs)
|
* requires golang 1.22.x or latest version
|
||||||
```shell
|
```shell
|
||||||
rm -rf feeds/packages/lang/golang
|
rm -rf feeds/packages/lang/golang
|
||||||
git clone https://github.com/sbwml/packages_lang_golang -b 20.x feeds/packages/lang/golang
|
git clone https://github.com/sbwml/packages_lang_golang -b 23.x feeds/packages/lang/golang
|
||||||
```
|
```
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
|
13
install.sh
13
install.sh
@ -13,6 +13,13 @@ else
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check
|
||||||
|
if [ ! -d "/usr/share/luci/menu.d" ]; then
|
||||||
|
echo -e "${RED_COLOR}OpenWrt LuCI version is not supports.${RES}"
|
||||||
|
echo -e "${RED_COLOR}Minimum OpenWrt Version: openwrt-21.02 or latest${RES}"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# TMP
|
# TMP
|
||||||
TMPDIR=$(mktemp -d) || exit 1
|
TMPDIR=$(mktemp -d) || exit 1
|
||||||
|
|
||||||
@ -22,7 +29,7 @@ country_code=$(echo $ip_info | sed -r 's/.*country_code":"([^"]*).*/\1/')
|
|||||||
if [ $country_code = "CN" ]; then
|
if [ $country_code = "CN" ]; then
|
||||||
google_status=$(curl -I -4 -m 3 -o /dev/null -s -w %{http_code} http://www.google.com/generate_204)
|
google_status=$(curl -I -4 -m 3 -o /dev/null -s -w %{http_code} http://www.google.com/generate_204)
|
||||||
if [ ! $google_status = "204" ];then
|
if [ ! $google_status = "204" ];then
|
||||||
mirror="https://hub.gitmirror.com/"
|
mirror="https://mirror.ghproxy.com/"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -40,10 +47,6 @@ CHECK() (
|
|||||||
if [[ ! $verif ]]; then
|
if [[ ! $verif ]]; then
|
||||||
echo -e "${RED_COLOR}Error! The current \"$platform\" platform is not currently supported.${RES}"
|
echo -e "${RED_COLOR}Error! The current \"$platform\" platform is not currently supported.${RES}"
|
||||||
exit 1;
|
exit 1;
|
||||||
else
|
|
||||||
echo -e "${GREEN_COLOR}Update opkg sources ...${RES}"
|
|
||||||
opkg update
|
|
||||||
opkg install luci-compat
|
|
||||||
fi
|
fi
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user