更新一键脚本

This commit is contained in:
LanYun
2024-01-23 22:35:37 +08:00
parent 229dfda634
commit 067c50bafa
2 changed files with 17 additions and 7 deletions

View File

@@ -1,27 +1,35 @@
#!/bin/bash
# 错误处理函数
# shellcheck disable=SC2317 # Don't warn about unreachable commands in this function
handle_error() {
echo ""
echo "⚠️ 脚本发生错误!,请检查错误,正在后退出..."
echo "脚本发生错误,正在退出..."
exit 1
}
# 定义信号处理函数,用于响应 Ctrl+C
function handle_ctrl_c {
echo ""
echo "接收到 Ctrl+C正在退出..."
exit 0
echo "接收到 Ctrl+C正在退出..."
exit 0
}
function exit_execute {
echo "进程被杀死"
exit 0
}
# 设置信号处理程序,捕捉 SIGINT 信号Ctrl+C
trap handle_ctrl_c SIGINT
# 设置trap命令捕捉SIGTERM信号并调用exit_execute函数
trap exit_execute SIGTERM
# 设置错误处理函数
trap handle_error ERR
function Wipes_Data {
user=$(whoami)
user=$SUDO_USER
sudo rm -rf "/Applications/Surge.app" || true
sudo rm -rf "/tmp/Surge-*.zip" || true
@@ -52,7 +60,9 @@ cd "${SCRIPT_DIR}" || exit 1
echo "⚙️ 是否需要清除Surge相关内容?"
echo "⚙️ 若需要全新安装Surge,请输入y并回车,只进行破解,直接回车即可."
read -r flag
sudo killall Surge || true
read -r flag || true
if [[ $flag == y ]]; then
echo "⚙️ 若你安装过Surge,请确保Surge卸载干净,建议用App Cleaner & Uninstaller工具"
echo '⚙️ 若你有配置文件等信息,请备份到其他目录,都确认无误后输入y,开始纯净安装!'

View File

@@ -213,7 +213,7 @@ https://twitter.com/QiuChenly
| Camtasia 2023 | [2023.3.4(124306)通杀](https://www.techsmith.com/camtasia.html) | ✅ | ✅ | ✅ | 通殺不要問為什麼 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| Final Cut Pro Trial | [(10.6.10)通杀](https://secure-appldnld.apple.com/Final_Cut_Pro_X/042-60959-20231004-B5BFDED9-9530-49C9-97EB-B7B617BC5026/FinalCutProTrial.dmg) | ✅ | ✅ | ✅ | 通殺不要問為什麼 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| MacUpdater | [激活码通杀](https://www.corecode.io/downloads/macupdater_latest.dmg) | ✅ | ✅ | ✅ | 通殺序列号下面找 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| Surge 5 | [5.4.4-2548](https://dl.nssurge.com/mac/v5/Surge-5.4.4-2548-d7d99d568f03d3a87a049d3b6148bee6.zip) | ✅ | ✅ | ✅ | 老有聪明人自己没搞好出问题来问我该怎么办 不是我的问题我怎么知道怎么办?你不问开发者你问我?傻逼吧你? | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| Surge 5 | [5.4.4-2558](https://dl.nssurge.com/mac/v5/Surge-5.4.4-2558-7f44bd9ea3f6ea91a5dd6f4f441ed5b4.zip) | ✅ | ✅ | ✅ | 老有聪明人自己没搞好出问题来问我该怎么办 不是我的问题我怎么知道怎么办?你不问开发者你问我?傻逼吧你? | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| CleanShot | [4.6.2](https://updates.getcleanshot.com/v3/CleanShot-X-4.6.2.dmg) | ✅ | ✅ | ✅ | 不通杀 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| com.edrawsoft.edrawmax/com.edrawsoft.mindmaster | 自己去官网下 | ✅ | ✅ | ✅ | 不通杀 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |
| UlyssesMac | [MAS版本](https://apps.apple.com/us/app/ulysses-%E5%86%99%E4%BD%9C-%E7%AC%94%E8%AE%B0-%E6%97%A5%E8%AE%B0-%E5%8D%9A%E5%AE%A2/id1225570693?l=zh-Hans-CN) | ✅ | ✅ | ✅ | 苹果应用商店版本,后续版本通杀 | [QiuChenly](https://github.com/QiuChenly) | ✅正常维护中 |