~修复Zashboard面板在小闪存模式下无法正常使用的bug
~修复部分极端情况下卸载脚本时会删除系统根目录的bug
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -4,5 +4,5 @@ clash_v=v1.7.1
|
|||||||
meta_v=v1.19.11
|
meta_v=v1.19.11
|
||||||
singboxp_v=1.10.0-alpha.29-067c81a7
|
singboxp_v=1.10.0-alpha.29-067c81a7
|
||||||
singbox_v=1.10.7
|
singbox_v=1.10.7
|
||||||
versionsh=1.9.2beta3
|
versionsh=1.9.2beta4
|
||||||
GeoIP_v=20250707
|
GeoIP_v=20250707
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# Copyright (C) Juewuy
|
# Copyright (C) Juewuy
|
||||||
|
|
||||||
version=1.9.2beta3
|
version=1.9.2beta4
|
||||||
|
|
||||||
setdir() {
|
setdir() {
|
||||||
dir_avail() {
|
dir_avail() {
|
||||||
|
|||||||
@@ -1825,23 +1825,31 @@ autoSSH() {
|
|||||||
uninstall() {
|
uninstall() {
|
||||||
read -p "确认卸载ShellCrash?(警告:该操作不可逆!)[1/0] > " res
|
read -p "确认卸载ShellCrash?(警告:该操作不可逆!)[1/0] > " res
|
||||||
if [ "$res" = '1' ]; then
|
if [ "$res" = '1' ]; then
|
||||||
|
#停止服务
|
||||||
${CRASHDIR}/start.sh stop 2>/dev/null
|
${CRASHDIR}/start.sh stop 2>/dev/null
|
||||||
${CRASHDIR}/start.sh cronset "clash服务" 2>/dev/null
|
${CRASHDIR}/start.sh cronset "clash服务" 2>/dev/null
|
||||||
${CRASHDIR}/start.sh cronset "订阅链接" 2>/dev/null
|
${CRASHDIR}/start.sh cronset "订阅链接" 2>/dev/null
|
||||||
${CRASHDIR}/start.sh cronset "ShellCrash初始化" 2>/dev/null
|
${CRASHDIR}/start.sh cronset "ShellCrash初始化" 2>/dev/null
|
||||||
${CRASHDIR}/start.sh cronset "task.sh" 2>/dev/null
|
${CRASHDIR}/start.sh cronset "task.sh" 2>/dev/null
|
||||||
read -p "是否保留脚本配置及订阅文件?[1/0] > " res
|
#移除安装目录
|
||||||
if [ "$res" = '1' ]; then
|
if [ -n "${CRASHDIR}" ] && [ "${CRASHDIR}" != '/' ];then
|
||||||
mv -f ${CRASHDIR}/configs /tmp/ShellCrash
|
read -p "是否保留脚本配置及订阅文件?[1/0] > " res
|
||||||
mv -f ${CRASHDIR}/yamls /tmp/ShellCrash
|
if [ "$res" = '1' ]; then
|
||||||
mv -f ${CRASHDIR}/jsons /tmp/ShellCrash
|
mv -f ${CRASHDIR}/configs /tmp/ShellCrash
|
||||||
rm -rf ${CRASHDIR}/*
|
mv -f ${CRASHDIR}/yamls /tmp/ShellCrash
|
||||||
mv -f /tmp/ShellCrash/configs ${CRASHDIR}
|
mv -f ${CRASHDIR}/jsons /tmp/ShellCrash
|
||||||
mv -f /tmp/ShellCrash/yamls ${CRASHDIR}
|
rm -rf ${CRASHDIR}/*
|
||||||
mv -f /tmp/ShellCrash/jsons ${CRASHDIR}
|
mv -f /tmp/ShellCrash/configs ${CRASHDIR}
|
||||||
|
mv -f /tmp/ShellCrash/yamls ${CRASHDIR}
|
||||||
|
mv -f /tmp/ShellCrash/jsons ${CRASHDIR}
|
||||||
|
else
|
||||||
|
rm -rf ${CRASHDIR}
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
rm -rf ${CRASHDIR}
|
echo -e "\033[31m环境变量配置有误,请尝试手动移除安装目录!\033[0m"
|
||||||
|
sleep 1
|
||||||
fi
|
fi
|
||||||
|
#移除其他内容
|
||||||
[ -w ~/.bashrc ] && profile=~/.bashrc
|
[ -w ~/.bashrc ] && profile=~/.bashrc
|
||||||
[ -w /etc/profile ] && profile=/etc/profile
|
[ -w /etc/profile ] && profile=/etc/profile
|
||||||
sed -i '/alias clash=*/'d $profile
|
sed -i '/alias clash=*/'d $profile
|
||||||
@@ -1871,8 +1879,9 @@ uninstall() {
|
|||||||
echo -e "\033[33m请手动关闭当前窗口以重置环境变量!\033[0m"
|
echo -e "\033[33m请手动关闭当前窗口以重置环境变量!\033[0m"
|
||||||
echo -----------------------------------------------
|
echo -----------------------------------------------
|
||||||
exit
|
exit
|
||||||
|
else
|
||||||
|
echo -e "\033[31m操作已取消!\033[0m"
|
||||||
fi
|
fi
|
||||||
echo -e "\033[31m操作已取消!\033[0m"
|
|
||||||
}
|
}
|
||||||
tools() {
|
tools() {
|
||||||
ssh_tools() {
|
ssh_tools() {
|
||||||
|
|||||||
Reference in New Issue
Block a user