Update Packages support

This commit is contained in:
喵二
2024-07-12 19:03:38 +08:00
committed by GitHub
parent 5d7f41a8cf
commit df7db3bf67

View File

@@ -850,6 +850,13 @@ sysupgrade(){
firmware_url=$AMD64_BIOS_SYSUP
fi
if [ -f /etc/catwrt_opkg_list_installed ]; then
rm /etc/catwrt_opkg_list_installed
fi
catwrt_opkg_list_installed
echo "已经生成备份软件包列表,方便你后续更新后恢复部分消失的插件和软件"
echo ""
echo "Warning:"
echo "========================================================================="
@@ -887,56 +894,124 @@ sysupgrade(){
# catwrt_opkg_list_installed
catwrt_opkg_list_installed(){
PACKAGES=(
"luci-app-aria2"
"luci-app-acme"
"luci-app-adguardhome"
"luci-app-ssr-plus"
"luci-app-passwall"
"luci-app-openclash"
"luci-app-oaf"
"luci-app-mosdns"
"luci-app-ddns-go"
"luci-app-store"
"luci-app-adbyby-plus"
"luci-i18n-adbyby-plus-zh-cn"
"luci-app-adblock"
"luci-i18n-adblock-zh-cn"
"luci-app-airplay2"
"luci-i18n-airplay2-zh-cn"
"luci-app-design-config"
"luci-i18n-design-config-zh-cn"
"luci-app-argon-config"
"luci-app-cifs-mount"
"luci-app-diskman"
"luci-i18n-diskman-zh-cn"
"luci-app-ddns-go"
"luci-i18n-ddns-go-zh-cn"
"luci-app-frpc"
"luci-i18n-frpc-zh-cn"
"luci-app-frps"
"luci-i18n-frps-zh-cn"
"luci-app-ipsec-server"
"luci-i18n-ipsec-server-zh-cn"
"luci-app-ipsec-vpnd"
"luci-i18n-ipsec-vpnd-zh-cn"
"luci-app-mwan3"
"luci-i18n-mwan3-zh-cn"
"luci-app-mwan3helper"
"luci-i18n-mwan3helper-zh-cn"
"luci-app-n2n"
"luci-i18n-n2n-zh-cn"
"luci-app-nps"
"luci-i18n-nps-zh-cn"
"luci-app-openvpn-server"
"luci-i18n-openvpn-server-zh-cn"
"luci-app-openvpn"
"luci-i18n-openvpn-zh-cn"
"luci-app-oaf"
"luci-i18n-oaf-zh-cn"
"luci-app-netdata"
"luci-i18n-netdata-zh-cn"
"luci-app-pppoe-relay"
"luci-i18n-pppoe-relay-zh-cn"
"luci-app-qbittorrent"
"luci-i18n-qbittorrent-zh-cn"
"luci-app-qos"
"luci-i18n-qos-zh-cn"
"luci-app-samba4"
"luci-i18n-samba4-zh-cn"
"luci-app-smartdns"
"luci-i18n-smartdns-zh-cn"
"luci-app-socat"
"luci-i18n-socat-zh-cn"
"luci-app-sqm"
"luci-i18n-sqm-zh-cn"
"luci-app-transmission"
"luci-i18n-transmission-zh-cn"
"luci-app-ttyd"
"luci-i18n-ttyd-zh-cn"
"luci-app-udpxy"
"luci-i18n-udpxy-zh-cn"
"luci-app-uhttpd"
"luci-i18n-uhttpd-zh-cn"
"luci-app-unblockmusic"
"luci-i18n-unblockmusic-zh-cn"
"luci-app-uugamebooster"
"luci-i18n-uugamebooster-zh-cn"
"luci-app-wireguard"
"luci-i18n-wireguard-zh-cn"
"luci-app-xlnetacc"
"luci-i18n-xlnetacc-zh-cn"
"luci-app-zerotier"
"luci-i18n-zerotier-zh-cn"
"luci-app-dockerman"
"luci-app-usb-printer"
"luci-i18n-usb-printer-zh-cn"
"luci-i18n-dockerman-zh-cn"
"luci-app-docker"
"luci-i18n-docker-zh-cn"
"luci-app-ssr-plus"
"luci-i18n-ssr-plus-zh-cn"
"luci-app-passwall"
"luci-i18n-passwall-zh-cn"
"luci-app-passwall2"
"luci-i18n-passwall2-zh-cn"
"luci-app-openclash"
"luci-app-poweroff"
"luci-app-passwall2"
"luci-i18n-passwall2-zh-cn"
"luci-app-LingTiGameAcc"
"luci-app-usb3disable"
"luci-app-pushbot"
"luci-app-store"
"luci-app-serverchan"
"luci-app-nezha-agent"
"luci-theme-design"
"luci-app-design-config"
"luci-theme-argon"
"luci-app-argon-config"
"luci-app-eqos"
"ua2f"
"vim"
"nano"
"nginx"
"ethtool"
"tailscale"
"igmpproxy"
"openssh-client"
"openssh-keygen"
"openssh-server"
"openssh-sftp-server"
"kmod-usb2"
"kmod-usb3"
"kmod-usb-net-ipheth"
"libimobiledevice-utils"
"usbmuxd"
"kmod-usb-net-rndis"
"kmod-nls-base"
"kmod-usb-core"
"kmod-usb-net"
"kmod-usb-net-cdc-ether"
)
if ! grep -q -E "catwrt|repo.miaoer.xyz" /etc/opkg/distfeeds.conf && ! ip a | grep -q -E "192\.168\.[0-9]+\.[0-9]+|10\.[0-9]+\.[0-9]+\.[0-9]+|172\.1[6-9]\.[0-9]+\.[0-9]+|172\.2[0-9]+\.[0-9]+|172\.3[0-1]\.[0-9]+\.[0-9]+"; then