From a76b0ed71c2d049973abf67cdd22216844ac6b68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=85=8E=E9=A5=BC=E6=9E=9C=E5=AD=90=E5=8D=B7=E9=B2=A8?= =?UTF-8?q?=E9=B1=BC=E8=BE=A3=E6=A4=92?= Date: Fri, 24 Jan 2025 23:06:25 +0800 Subject: [PATCH] Add instructions to disable auto-update feature in README files and update script - Introduced a new section in both English and Chinese README files detailing methods to disable the auto-update feature for Cursor, including a built-in script and manual steps for Windows, macOS, and Linux. - Updated the cursor_win_id_modifier.ps1 script to prompt users for disabling auto-update, enhancing user interaction and control over application settings. - Included warnings about the need for manual updates after disabling the auto-update feature, improving overall user guidance. --- README.md | 48 +++++++++++++++++++++++++ README_CN.md | 49 ++++++++++++++++++++++++++ scripts/run/cursor_win_id_modifier.ps1 | 2 +- 3 files changed, 98 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e7a64bd..3b72daa 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,53 @@ > > Please check your Cursor version before using this tool. + +
+🔒 Disable Auto-Update Feature + +> To prevent Cursor from automatically updating to unsupported new versions, you can choose to disable the auto-update feature. + +#### Method 1: Using Built-in Script (Recommended) + +When running the reset tool, the script will ask if you want to disable auto-updates: +```text +[Question] Do you want to disable Cursor auto-update feature? +0) No - Keep default settings (Press Enter) +1) Yes - Disable auto-update +``` + +Select `1` to automatically complete the disable operation. + +#### Method 2: Manual Disable + +**Windows:** +1. Close all Cursor processes +2. Delete directory: `%LOCALAPPDATA%\cursor-updater` +3. Create a file with the same name (without extension) in the same location + +**macOS:** +```bash +# Close Cursor +pkill -f "Cursor" +# Remove update directory and create blocking file +rm -rf ~/Library/Application\ Support/cursor-updater +touch ~/Library/Application\ Support/cursor-updater +``` + +**Linux:** +```bash +# Close Cursor +pkill -f "Cursor" +# Remove update directory and create blocking file +rm -rf ~/.config/cursor-updater +touch ~/.config/cursor-updater +``` + +> ⚠️ **Note:** After disabling auto-updates, you'll need to manually download and install new versions. It's recommended to update only after confirming the new version is compatible. + + +
+ --- ### 📝 Description @@ -356,3 +403,4 @@ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + diff --git a/README_CN.md b/README_CN.md index ccd1c75..04800bf 100644 --- a/README_CN.md +++ b/README_CN.md @@ -20,6 +20,52 @@ > > 使用前请确认您的 Cursor 版本。 +
+🔒 禁用自动更新功能 + +> 为防止 Cursor 自动更新到不支持的新版本,您可以选择禁用自动更新功能。 + +#### 方法一:使用内置脚本(推荐) + +在运行重置工具时,脚本会询问是否要禁用自动更新: +```text +[询问] 是否要禁用 Cursor 自动更新功能? +0) 否 - 保持默认设置 (按回车键) +1) 是 - 禁用自动更新 +``` + +选择 `1` 即可自动完成禁用操作。 + +#### 方法二:手动禁用 + +**Windows:** +1. 关闭所有 Cursor 进程 +2. 删除目录:`%LOCALAPPDATA%\cursor-updater` +3. 在相同位置创建同名文件(不带扩展名) + +**macOS:** +```bash +# 关闭 Cursor +pkill -f "Cursor" +# 删除更新目录并创建阻止文件 +rm -rf ~/Library/Application\ Support/cursor-updater +touch ~/Library/Application\ Support/cursor-updater +``` + +**Linux:** +```bash +# 关闭 Cursor +pkill -f "Cursor" +# 删除更新目录并创建阻止文件 +rm -rf ~/.config/cursor-updater +touch ~/.config/cursor-updater +``` + +> ⚠️ **注意:** 禁用自动更新后,需要手动下载并安装新版本。建议在确认新版本可用后再更新。 + + +
+ --- ### 📝 问题描述 @@ -290,6 +336,9 @@ macOS/Linux 用户可以尝试在系统中找到类似的`cursor-updater`目录 - ✅ 错误处理和恢复 + + + ## 联系方式
diff --git a/scripts/run/cursor_win_id_modifier.ps1 b/scripts/run/cursor_win_id_modifier.ps1 index 24610e8..05702fa 100644 --- a/scripts/run/cursor_win_id_modifier.ps1 +++ b/scripts/run/cursor_win_id_modifier.ps1 @@ -296,7 +296,7 @@ Write-Host "" Write-Host "$YELLOW[询问]$NC 是否要禁用 Cursor 自动更新功能?" Write-Host "0) 否 - 保持默认设置 (按回车键)" Write-Host "1) 是 - 禁用自动更新" -$choice = Read-Host "请输入选项 (1 或直接回车)" +$choice = Read-Host "请输入选项 (1)" if ($choice -eq "1") { Write-Host ""