Compare commits

...

14 Commits

Author SHA1 Message Date
煎饼果子卷鲨鱼辣椒
9a0a1260e0 gg 2025-06-05 15:01:33 +08:00
煎饼果子卷鲨鱼辣椒
a864cf9284 gg 2025-06-05 11:56:37 +08:00
煎饼果子卷鲨鱼辣椒
f3953cd838 移除 Cursor 初始化清理函数的调用,这个方法还需要琢磨一下 2025-05-30 09:54:58 +08:00
煎饼果子卷鲨鱼辣椒
a48185e6a5 支持0.50.x 2025-05-29 17:41:46 +08:00
煎饼果子卷鲨鱼辣椒
c1b7e42e27 新增 Cursor 初始化清理函数以删除不必要的文件和文件夹,提升脚本的稳定性和用户体验。该函数在 Linux 和 macOS 环境下均进行了实现,确保用户配置的清理工作能够顺利完成。 2025-05-29 17:08:19 +08:00
煎饼果子卷鲨鱼辣椒
776ecb0434 新增 Cursor 初始化函数以清理不必要的文件和文件夹,提升脚本的稳定性和用户体验。同时修复了路径字符串中的转义字符问题,确保在 Windows 环境下的兼容性。 2025-05-29 16:57:21 +08:00
煎饼果子卷鲨鱼辣椒
86b2bae098 更新 README 文件中的微信群二维码,替换为新的二维码图片(qun13.png),以确保用户获取最新的联系方式。 2025-05-23 09:50:38 +08:00
煎饼果子卷鲨鱼辣椒
291c6198bc Merge branch 'master' of https://github.com/yuaotian/go-cursor-help 2025-05-05 18:12:58 +08:00
煎饼果子卷鲨鱼辣椒
bc787f2076 新增辅助函数以判断接口类型、生成本地管理+单播MAC地址,并自动检测并调用第三方工具(macchanger或spoof-mac)以增强MAC地址修改功能的可靠性。同时,优化了临时禁用和重新启用接口的逻辑,提供了失败时的恢复/重试选项,提升了用户体验和脚本的稳定性。 2025-05-05 18:11:08 +08:00
煎饼果子卷鲨鱼辣椒@86
9204cef000
Merge pull request #490 from yunfeidog/master
fix(mac): 修复mac无法正确修改接口MAC地址的问题
2025-05-04 16:12:59 +08:00
yunfeidog
363518ad40 fix(mac): 修复mac环境下无法成功修改MAC地址的问题 2025-05-04 14:03:33 +08:00
煎饼果子卷鲨鱼辣椒
d01dcdb7ba 新增 Cursor 安装相关功能,优化了查找和安装过程。包括添加标准安装路径、改进资源目录查找逻辑、实现从本地 AppImage 安装 Cursor 的功能,并增强了日志记录以提高用户体验。同时,更新了配置文件处理逻辑,确保在备份和修改过程中更具可靠性。此更改旨在提升脚本的稳定性和用户友好性。 2025-04-30 12:31:45 +08:00
煎饼果子卷鲨鱼辣椒
234ec180a0 qun-12 2025-04-29 10:17:18 +08:00
煎饼果子卷鲨鱼辣椒
974852944b 在临时修改系统 MAC 地址的功能中,更新了调用方式以确保即使在执行过程中出现错误也不会中断后续操作。此更改通过在调用 change_system_mac_address 函数时添加 || true,提升了脚本的稳定性和用户体验。 2025-04-27 20:45:28 +08:00
9 changed files with 1202 additions and 550 deletions

View File

@ -15,8 +15,8 @@
> ⚠️ **IMPORTANT NOTICE**
>
> This tool currently supports:
> - ✅ Windows: Latest 0.49.x versions (Supported)
> - ✅ Mac/Linux: Latest 0.49.x versions (Supported, feedback welcome)
> - ✅ Windows: Latest 0.50.x versions (Supported)
> - ✅ Mac/Linux: Latest 0.50.x versions (Supported, feedback welcome)
>
> Please check your Cursor version before using this tool.
@ -503,8 +503,8 @@ Modifying this registry key may affect:
</td>
<td align="center">
<b>WeChat</b><br>
<img src="img/qun11.jpg" width="500" alt="WeChat"><br>
<em>二维码7天内(4月25日前)有效,过期请加微信</em>
<img src="img/qun13.png" width="500" alt="WeChat"><br>
<em>二维码7天内(5月30日前)有效,过期请加微信</em>
</td>
<!-- <td align="center">
<b>ETC</b><br>

View File

@ -15,8 +15,8 @@
> ⚠️ **重要提示**
>
> 本工具当前支持版本:
> - ✅ Windows: 最新的 0.49.x 版本(已支持)
> - ✅ Mac/Linux: 最新的 0.49.x 版本(已支持,欢迎测试并反馈问题)
> - ✅ Windows: 最新的 0.50.x 版本(已支持)
> - ✅ Mac/Linux: 最新的 0.50.x 版本(已支持,欢迎测试并反馈问题)
> 使用前请确认您的 Cursor 版本。
@ -442,8 +442,8 @@ irm https://raw.githubusercontent.com/yuaotian/go-cursor-help/refs/heads/master/
</td>
<td align="center">
<b>微信交流群</b><br>
<img src="img/qun11.jpg" width="500" alt="WeChat"><br>
<small>二维码7天内(4月25日前)有效,过期请加微信</small>
<img src="img/qun13.png" width="500" alt="WeChat"><br>
<small>二维码7天内(5月30日前)有效,过期请加微信</small>
</td>
<td align="center">
<b>公众号</b><br>

View File

@ -15,8 +15,8 @@
> ⚠️ **重要なお知らせ**
>
> このツールは現在以下のバージョンをサポートしています:
> - ✅ Windows: 最新の0.49.xバージョンサポート済み
> - ✅ Mac/Linux: 最新の0.49.xバージョンサポート済み、フィードバック歓迎
> - ✅ Windows: 最新の0.50.xバージョンサポート済み
> - ✅ Mac/Linux: 最新の0.50.xバージョンサポート済み、フィードバック歓迎
>
> このツールを使用する前に、Cursorのバージョンを確認してください。
@ -500,8 +500,8 @@ macOS/Linuxユーザーはシステム内で同様の`cursor-updater`ディレ
</td>
<td align="center">
<b>WeChat</b><br>
<img src="img/qun11.jpg" width="500" alt="WeChat"><br>
<em>二维码7天内(4月25日前)有效,过期请加微信</em>
<img src="img/qun13.png" width="500" alt="WeChat"><br>
<em>二维码7天内(5月30日前)有效,过期请加微信</em>
</td>
<!-- <td align="center">
<b>ETC</b><br>

BIN
img/qun-12.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

BIN
img/qun13.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

View File

@ -3,7 +3,7 @@
AppImage instructions:
mkdir -p ~/Downloads/Cursor
cd ~/Downloads/Cursor
cd Cursor && ./Cursor-0.49.5-x86_64.AppImage --appimage-extract
cd Cursor && ./Cursor-0.50.5-x86_64.AppImage --appimage-extract
mkdir -p ~/.local
rsync -rt ~/Downloads/Cursor/squashfs-root/usr/ ~/.local
# ^ copy the subfolders not usr itself, so the resulting executable should be ~/.local/bin/cursor

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -13,6 +13,70 @@ $NC = "`e[0m"
$STORAGE_FILE = "$env:APPDATA\Cursor\User\globalStorage\storage.json"
$BACKUP_DIR = "$env:APPDATA\Cursor\User\globalStorage\backups"
# 新增 Cursor 初始化函数
function Cursor-初始化 {
Write-Host "$GREEN[信息]$NC 正在执行 Cursor 初始化清理..."
$BASE_PATH = "$env:APPDATA\Cursor\User"
$filesToDelete = @(
(Join-Path -Path $BASE_PATH -ChildPath "globalStorage\\state.vscdb"),
(Join-Path -Path $BASE_PATH -ChildPath "globalStorage\\state.vscdb.backup")
)
$folderToCleanContents = Join-Path -Path $BASE_PATH -ChildPath "History"
$folderToDeleteCompletely = Join-Path -Path $BASE_PATH -ChildPath "workspaceStorage"
Write-Host "$BLUE[调试]$NC 基础路径: $BASE_PATH"
# 删除指定文件
foreach ($file in $filesToDelete) {
Write-Host "$BLUE[调试]$NC 检查文件: $file"
if (Test-Path $file) {
try {
Remove-Item -Path $file -Force -ErrorAction Stop
Write-Host "$GREEN[成功]$NC 已删除文件: $file"
}
catch {
Write-Host "$RED[错误]$NC 删除文件 $file 失败: $($_.Exception.Message)"
}
} else {
Write-Host "$YELLOW[警告]$NC 文件不存在,跳过删除: $file"
}
}
# 清空指定文件夹内容
Write-Host "$BLUE[调试]$NC 检查待清空文件夹: $folderToCleanContents"
if (Test-Path $folderToCleanContents) {
try {
# 获取子项进行删除,以避免删除 History 文件夹本身
Get-ChildItem -Path $folderToCleanContents -Recurse | Remove-Item -Recurse -Force -ErrorAction Stop
Write-Host "$GREEN[成功]$NC 已清空文件夹内容: $folderToCleanContents"
}
catch {
Write-Host "$RED[错误]$NC 清空文件夹 $folderToCleanContents 内容失败: $($_.Exception.Message)"
}
} else {
Write-Host "$YELLOW[警告]$NC 文件夹不存在,跳过清空: $folderToCleanContents"
}
# 删除指定文件夹及其内容
Write-Host "$BLUE[调试]$NC 检查待删除文件夹: $folderToDeleteCompletely"
if (Test-Path $folderToDeleteCompletely) {
try {
Remove-Item -Path $folderToDeleteCompletely -Recurse -Force -ErrorAction Stop
Write-Host "$GREEN[成功]$NC 已删除文件夹: $folderToDeleteCompletely"
}
catch {
Write-Host "$RED[错误]$NC 删除文件夹 $folderToDeleteCompletely 失败: $($_.Exception.Message)"
}
} else {
Write-Host "$YELLOW[警告]$NC 文件夹不存在,跳过删除: $folderToDeleteCompletely"
}
Write-Host "$GREEN[信息]$NC Cursor 初始化清理完成。"
Write-Host "" # 添加空行以改善输出格式
}
# 检查管理员权限
function Test-Administrator {
$user = [Security.Principal.WindowsIdentity]::GetCurrent()
@ -44,14 +108,15 @@ Write-Host "$GREEN Cursor 设备ID 修改工具 $NC"
Write-Host "$YELLOW 关注公众号【煎饼果子卷AI】 $NC"
Write-Host "$YELLOW 一起交流更多Cursor技巧和AI知识(脚本免费、关注公众号加群有更多技巧和大佬) $NC"
Write-Host "$YELLOW [重要提示] 本工具免费如果对您有帮助请关注公众号【煎饼果子卷AI】 $NC"
Write-Host "$BLUE================================$NC"
Write-Host ""
Write-Host "$YELLOW [小小广告] 出售CursorPro教育号一年质保三个月有需要找我(86)WeChatJavaRookie666 $NC"
Write-Host "$BLUE================================$NC"
# 获取并显示 Cursor 版本
function Get-CursorVersion {
try {
# 主要检测路径
$packagePath = "$env:LOCALAPPDATA\Programs\cursor\resources\app\package.json"
$packagePath = "$env:LOCALAPPDATA\\Programs\\cursor\\resources\\app\\package.json"
if (Test-Path $packagePath) {
$packageJson = Get-Content $packagePath -Raw | ConvertFrom-Json
@ -62,7 +127,7 @@ function Get-CursorVersion {
}
# 备用路径检测
$altPath = "$env:LOCALAPPDATA\cursor\resources\app\package.json"
$altPath = "$env:LOCALAPPDATA\\cursor\\resources\\app\\package.json"
if (Test-Path $altPath) {
$packageJson = Get-Content $altPath -Raw | ConvertFrom-Json
if ($packageJson.version) {
@ -85,7 +150,7 @@ function Get-CursorVersion {
$cursorVersion = Get-CursorVersion
Write-Host ""
Write-Host "$YELLOW[重要提示]$NC 最新的 0.49.x (以支持)"
Write-Host "$YELLOW[重要提示]$NC 最新的 0.50.x (以支持)"
Write-Host ""
# 检查并关闭 Cursor 进程
@ -139,6 +204,9 @@ function Close-CursorProcess {
Close-CursorProcess "Cursor"
Close-CursorProcess "cursor"
# 执行 Cursor 初始化清理
# Cursor-初始化
# 创建备份目录
if (-not (Test-Path $BACKUP_DIR)) {
New-Item -ItemType Directory -Path $BACKUP_DIR | Out-Null
@ -536,13 +604,4 @@ function Write-ConfigFile {
catch {
throw "写入配置文件失败: $_"
}
}
# 获取并显示版本信息
$cursorVersion = Get-CursorVersion
Write-Host ""
if ($cursorVersion) {
Write-Host "$GREEN[信息]$NC 检测到 Cursor 版本: $cursorVersion,继续执行..."
} else {
Write-Host "$YELLOW[警告]$NC 无法检测版本,将继续执行..."
}