cleanup of repo

This commit is contained in:
psipher
2026-01-26 11:49:22 +01:00
parent d295db6c9b
commit 4cd49cc015
11 changed files with 361 additions and 43 deletions

View File

@@ -11,18 +11,17 @@
[![License: CC BY-NC-ND 4.0](https://img.shields.io/badge/License-CC_BY--NC--ND_4.0-lightgrey.svg)](https://creativecommons.org/licenses/by-nc-nd/4.0/)
[![Stars](https://img.shields.io/endpoint?url=https://api.pinstudios.net/api/badges/stars/psipher/cursor-free-vip-main)](https://github.com/psipher/cursor-free-vip-main/stargazers)
[![Downloads](https://img.shields.io/endpoint?url=https://api.pinstudios.net/api/badges/downloads/psipher/cursor-free-vip-main/total)](https://github.com/psipher/cursor-free-vip-main/releases/latest)
<a href="https://buymeacoffee.com/yeongpin" target="_blank"><img alt="Buy Me a Coffee" src="https://img.shields.io/badge/Buy%20Me%20a%20Coffee-Support%20Me-FFDA33"></a>
[<img src="https://devin.ai/assets/deepwiki-badge.png" alt="Ask DeepWiki.com" height="20"/>](https://deepwiki.com/psipher/cursor-free-vip-main)
</p>
<a href="https://trendshift.io/repositories/13425" target="_blank"><img src="https://trendshift.io/api/badge/repositories/13425" alt="psipher%2Fcursor-free-vip-main | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a>
<br>
<h4>Support Latest 0.49.x Version</h4>
This tool is for educational purposes, currently the repo does not violate any laws. Please support the original project.
> [!NOTE]
> This project was originally forked from [cursor-free-vip](https://github.com/yeongpin/cursor-free-vip). Since the original repository is no longer receiving updates, I am maintaining this fork to ensure compatibility with the latest versions.
This tool registers accounts with custom emails, support Google and GitHub account registrations, temporary GitHub account registration, kills all Cursor's running processes, resets and wipes Cursor data and hardware info.
Supports Windows, macOS and Linux.
@@ -90,6 +89,29 @@ irm https://raw.githubusercontent.com/psipher/cursor-free-vip-main/main/scripts/
If you want to stop the script, please press Ctrl+C
### 🔐 Administrator Privileges Required (Windows)
**Important**: This application requires Administrator privileges on Windows to function properly.
**Quick Start Options:**
1. **Using the launcher scripts** (Recommended):
- Run `run_as_admin.bat` - Double-click and select "Run as administrator"
- Or run `run_as_admin.ps1` - PowerShell script with auto-elevation
2. **Manual PowerShell Admin**:
- Right-click Start button → Select "Terminal (Admin)" or "PowerShell (Admin)"
- Navigate to project directory: `cd "path\to\cursor-free-vip-main"`
- Run: `.\myenv\Scripts\python.exe main.py`
3. **Using built executable**:
- The compiled `.exe` will automatically request admin privileges
**Why Admin Rights?**
- Registry modifications for machine ID reset
- System-level file access for Cursor configuration
- Complete hardware fingerprint changes
## ❗ Note
📝 Config File Path: `[Documents/.cursor-free-vip/config.ini]`
@@ -161,13 +183,13 @@ email = xxxxx@mailto.plus
epin =
[WindowsPaths]
storage_path = C:\Users\yeongpin\AppData\Roaming\Cursor\User\globalStorage\storage.json
sqlite_path = C:\Users\yeongpin\AppData\Roaming\Cursor\User\globalStorage\state.vscdb
machine_id_path = C:\Users\yeongpin\AppData\Roaming\Cursor\machineId
cursor_path = C:\Users\yeongpin\AppData\Local\Programs\Cursor\resources\app
updater_path = C:\Users\yeongpin\AppData\Local\cursor-updater
update_yml_path = C:\Users\yeongpin\AppData\Local\Programs\Cursor\resources\app-update.yml
product_json_path = C:\Users\yeongpin\AppData\Local\Programs\Cursor\resources\app\product.json
storage_path = C:\Users\username\AppData\Roaming\Cursor\User\globalStorage\storage.json
sqlite_path = C:\Users\username\AppData\Roaming\Cursor\User\globalStorage\state.vscdb
machine_id_path = C:\Users\username\AppData\Roaming\Cursor\machineId
cursor_path = C:\Users\username\AppData\Local\Programs\Cursor\resources\app
updater_path = C:\Users\username\AppData\Local\cursor-updater
update_yml_path = C:\Users\username\AppData\Local\Programs\Cursor\resources\app-update.yml
product_json_path = C:\Users\username\AppData\Local\Programs\Cursor\resources\app\product.json
[Browser]
default_browser = opera
@@ -179,7 +201,7 @@ chrome_driver_path = D:\VisualCode\cursor-free-vip-new\drivers\chromedriver.exe
edge_driver_path = D:\VisualCode\cursor-free-vip-new\drivers\msedgedriver.exe
firefox_driver_path = D:\VisualCode\cursor-free-vip-new\drivers\geckodriver.exe
brave_driver_path = D:\VisualCode\cursor-free-vip-new\drivers\chromedriver.exe
opera_path = C:\Users\yeongpin\AppData\Local\Programs\Opera\opera.exe
opera_path = C:\Users\username\AppData\Local\Programs\Opera\opera.exe
opera_driver_path = D:\VisualCode\cursor-free-vip-new\drivers\chromedriver.exe
[OAuth]
@@ -214,21 +236,6 @@ Welcome to submit Issues and Pull Requests!
This tool is only for learning and research purposes, and any consequences arising from the use of this tool are borne by the user.
## 💰 Buy Me a Coffee
<div align="center">
<table>
<tr>
<td>
<img src="./images/provi-code.jpg" alt="buy_me_a_coffee" width="280"/><br>
</td>
<td>
<img src="./images/paypal.png" alt="buy_me_a_coffee" width="280"/><br>
</td>
</tr>
</table>
</div>
## ⭐ Star History
<div align="center">

View File

@@ -61,9 +61,15 @@ def build():
if os.path.exists('build'):
shutil.rmtree('build')
# Reload environment variables to ensure getting the latest version
load_dotenv(override=True)
version = os.getenv('VERSION', '1.0.0')
# Get version using the dynamic version system
try:
from version import get_version
version = get_version()
except ImportError:
# Fallback to environment variables
load_dotenv(override=True)
version = os.getenv('VERSION', os.getenv('VERSION_FALLBACK', '1.0.0'))
print(f"\033[93m📦 Building version: v{version}\033[0m")
try:

View File

@@ -1,11 +1,18 @@
# -*- mode: python ; coding: utf-8 -*-
import os
import platform
from dotenv import load_dotenv
# 加載環境變量獲取版本號
load_dotenv()
version = os.getenv('VERSION', '1.0.0')
# Get version using the dynamic version system
try:
import sys
sys.path.insert(0, '.')
from version import get_version
version = get_version()
except ImportError:
# Fallback to environment variables
from dotenv import load_dotenv
load_dotenv()
version = os.getenv('VERSION', os.getenv('VERSION_FALLBACK', '1.0.0'))
# 根据系统类型设置输出名称
system = platform.system().lower()

View File

@@ -0,0 +1,37 @@
# Create Desktop Shortcut for Cursor Free VIP
# Run this script to create a desktop shortcut that automatically runs as Administrator
$currentPath = Get-Location
$shortcutPath = [Environment]::GetFolderPath("Desktop") + "\Cursor Free VIP (Admin).lnk"
$targetPath = "$currentPath\run_as_admin.ps1"
# Create WScript.Shell object
$shell = New-Object -ComObject WScript.Shell
# Create shortcut
$shortcut = $shell.CreateShortcut($shortcutPath)
$shortcut.TargetPath = "powershell.exe"
$shortcut.Arguments = "-NoProfile -ExecutionPolicy Bypass -File `"$targetPath`""
$shortcut.WorkingDirectory = $currentPath
$shortcut.Description = "Cursor Free VIP - Run as Administrator"
$shortcut.IconLocation = "powershell.exe,0"
# Save shortcut
$shortcut.Save()
Write-Host ""
Write-Host "================================================================" -ForegroundColor Cyan
Write-Host " DESKTOP SHORTCUT CREATED SUCCESSFULLY!" -ForegroundColor Green
Write-Host "================================================================" -ForegroundColor Cyan
Write-Host ""
Write-Host "A desktop shortcut has been created: " -NoNewline -ForegroundColor White
Write-Host "Cursor Free VIP (Admin)" -ForegroundColor Yellow
Write-Host ""
Write-Host "You can now double-click the shortcut to run the application with" -ForegroundColor White
Write-Host "administrator privileges automatically." -ForegroundColor White
Write-Host ""
Write-Host "Shortcut location: " -NoNewline -ForegroundColor Cyan
Write-Host "$shortcutPath" -ForegroundColor White
Write-Host ""
Read-Host "Press Enter to continue"

View File

@@ -0,0 +1,47 @@
#!/usr/bin/env python3
"""
Quick script to disable the tool's update check to prevent the infinite update loop.
"""
import os
import sys
from pathlib import Path
def disable_update_check():
"""Disable the update check by modifying the main.py temporarily"""
main_py_path = Path(__file__).parent / "main.py"
if not main_py_path.exists():
print("❌ main.py not found!")
return False
try:
# Read the current main.py content
with open(main_py_path, 'r', encoding='utf-8') as f:
content = f.read()
# Find the update check line and comment it out
old_line = " check_latest_version(translator)"
new_line = " # check_latest_version(translator) # Temporarily disabled to fix update loop"
if old_line in content:
new_content = content.replace(old_line, new_line)
# Write the modified content back
with open(main_py_path, 'w', encoding='utf-8') as f:
f.write(new_content)
print("✅ Update check has been disabled!")
print(" The application will no longer check for updates automatically.")
print(" You can re-enable it by running: enable_tool_update_check.py")
return True
else:
print("❌ Could not find the update check line in main.py")
return False
except Exception as e:
print(f"❌ Error modifying main.py: {e}")
return False
if __name__ == "__main__":
disable_update_check()

View File

@@ -0,0 +1,46 @@
#!/usr/bin/env python3
"""
Script to re-enable the tool's update check.
"""
import os
import sys
from pathlib import Path
def enable_update_check():
"""Re-enable the update check by modifying the main.py"""
main_py_path = Path(__file__).parent / "main.py"
if not main_py_path.exists():
print("❌ main.py not found!")
return False
try:
# Read the current main.py content
with open(main_py_path, 'r', encoding='utf-8') as f:
content = f.read()
# Find the commented update check line and uncomment it
old_line = " # check_latest_version(translator) # Temporarily disabled to fix update loop"
new_line = " check_latest_version(translator)"
if old_line in content:
new_content = content.replace(old_line, new_line)
# Write the modified content back
with open(main_py_path, 'w', encoding='utf-8') as f:
f.write(new_content)
print("✅ Update check has been re-enabled!")
print(" The application will now check for updates automatically again.")
return True
else:
print("❌ Could not find the disabled update check line in main.py")
return False
except Exception as e:
print(f"❌ Error modifying main.py: {e}")
return False
if __name__ == "__main__":
enable_update_check()

View File

@@ -22,6 +22,10 @@
"temp_github_register": "Temporary GitHub Register",
"admin_required": "Running as executable, administrator privileges required.",
"admin_required_continue": "Continuing without administrator privileges.",
"admin_required_strict": "This application requires Administrator privileges to function properly.",
"admin_how_to": "Please run PowerShell as Administrator and try again.",
"admin_steps": "Steps:",
"admin_exit": "Exiting application...",
"coming_soon": "Coming Soon",
"fixed_soon": "Fixed Soon",
"contribute": "Contribute to the Project",

20
main.py
View File

@@ -711,14 +711,18 @@ def check_latest_version(translator_instance=None):
def main() -> None:
"""Main entry point for the application."""
try:
# Check for admin privileges if running as executable on Windows only
if platform.system() == 'Windows' and is_frozen() and not is_admin():
logger.warning("Running without admin privileges on Windows")
print(f"{Fore.YELLOW}{EMOJI['ADMIN']} {translator.get('menu.admin_required') if translator else 'Administrator privileges are required for some features'}{Style.RESET_ALL}")
if run_as_admin():
sys.exit(0) # Exit after requesting admin privileges
else:
print(f"{Fore.YELLOW}{EMOJI['INFO']} {translator.get('menu.admin_required_continue') if translator else 'Continuing without administrator privileges. Some features may not work correctly.'}{Style.RESET_ALL}")
# Always require admin privileges on Windows
if platform.system() == 'Windows' and not is_admin():
logger.error("Administrator privileges are required")
print(f"\n{Fore.RED}{EMOJI['ADMIN']} {translator.get('menu.admin_required_strict') if translator else 'This application requires Administrator privileges to function properly.'}{Style.RESET_ALL}")
print(f"{Fore.YELLOW}{EMOJI['INFO']} {translator.get('menu.admin_how_to') if translator else 'Please run PowerShell as Administrator and try again.'}{Style.RESET_ALL}")
print(f"{Fore.CYAN}{EMOJI['INFO']} {translator.get('menu.admin_steps') if translator else 'Steps:'}{Style.RESET_ALL}")
print(f" {Fore.WHITE}1. Right-click Start button → Select 'Terminal (Admin)' or 'PowerShell (Admin)'{Style.RESET_ALL}")
print(f" {Fore.WHITE}2. Navigate to: cd \"{os.getcwd()}\"{Style.RESET_ALL}")
print(f" {Fore.WHITE}3. Run: .\\myenv\\Scripts\\python.exe main.py{Style.RESET_ALL}")
print(f"\n{Fore.RED}{EMOJI['ERROR']} {translator.get('menu.admin_exit') if translator else 'Exiting application...'}{Style.RESET_ALL}")
input(f"\n{Fore.YELLOW}Press Enter to exit...{Style.RESET_ALL}")
sys.exit(1)
# Display logo
print_logo()

45
run_as_admin.bat Normal file
View File

@@ -0,0 +1,45 @@
@echo off
REM Cursor Free VIP - Admin Launcher
REM This batch file helps run the application with administrator privileges
echo.
echo ================================================================
echo CURSOR FREE VIP - ADMIN LAUNCHER
echo ================================================================
echo.
echo This application requires Administrator privileges to function properly.
echo.
REM Check if running as administrator
net session >nul 2>&1
if %errorLevel% == 0 (
echo [OK] Running with Administrator privileges
echo.
echo Starting Cursor Free VIP...
echo.
REM Change to script directory
cd /d "%~dp0"
REM Run the application
.\myenv\Scripts\python.exe main.py
echo.
echo Application has exited.
pause
) else (
echo [!] Administrator privileges required
echo.
echo Please run this batch file as Administrator:
echo 1. Right-click on 'run_as_admin.bat'
echo 2. Select 'Run as administrator'
echo 3. Click 'Yes' when prompted by UAC
echo.
echo Alternatively, use PowerShell as Administrator:
echo 1. Right-click Start button
echo 2. Select 'Terminal (Admin)' or 'PowerShell (Admin)'
echo 3. Navigate to: cd "%~dp0"
echo 4. Run: .\myenv\Scripts\python.exe main.py
echo.
pause
)

115
run_as_admin.ps1 Normal file
View File

@@ -0,0 +1,115 @@
# Cursor Free VIP - Admin Launcher (PowerShell)
# This script helps run the application with administrator privileges
param(
[switch]$Force
)
# Function to check if running as administrator
function Test-Administrator {
if ($PSVersionTable.Platform -eq "Unix") {
return $true # Skip admin check on Unix systems
}
$currentUser = [Security.Principal.WindowsIdentity]::GetCurrent()
$principal = New-Object Security.Principal.WindowsPrincipal($currentUser)
return $principal.IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)
}
# Function to restart as administrator
function Start-AsAdmin {
$scriptPath = $MyInvocation.MyCommand.Path
$arguments = "-NoProfile -ExecutionPolicy Bypass -File `"$scriptPath`" -Force"
try {
Start-Process powershell -Verb RunAs -ArgumentList $arguments
exit
}
catch {
Write-Host "Failed to restart as administrator: $_" -ForegroundColor Red
return $false
}
}
# Main script
Write-Host ""
Write-Host "================================================================" -ForegroundColor Cyan
Write-Host " CURSOR FREE VIP - ADMIN LAUNCHER" -ForegroundColor Cyan
Write-Host "================================================================" -ForegroundColor Cyan
Write-Host ""
# Check if on Windows and if administrator privileges are required
if ($PSVersionTable.Platform -ne "Unix") {
if (-not (Test-Administrator)) {
if (-not $Force) {
Write-Host "[!] Administrator privileges required" -ForegroundColor Yellow
Write-Host ""
Write-Host "This application requires Administrator privileges to function properly." -ForegroundColor White
Write-Host ""
Write-Host "Options:" -ForegroundColor Cyan
Write-Host " 1. Allow this script to restart as Administrator (Recommended)" -ForegroundColor White
Write-Host " 2. Manually run PowerShell as Administrator" -ForegroundColor White
Write-Host ""
$choice = Read-Host "Would you like to restart as Administrator? (Y/n)"
if ($choice -eq "" -or $choice -eq "Y" -or $choice -eq "y") {
Write-Host "Restarting as Administrator..." -ForegroundColor Green
Start-AsAdmin
return
}
else {
Write-Host ""
Write-Host "Please manually run PowerShell as Administrator:" -ForegroundColor Yellow
Write-Host " 1. Right-click Start button" -ForegroundColor White
Write-Host " 2. Select 'Terminal (Admin)' or 'PowerShell (Admin)'" -ForegroundColor White
Write-Host " 3. Navigate to: cd `"$PWD`"" -ForegroundColor White
Write-Host " 4. Run: .\myenv\Scripts\python.exe main.py" -ForegroundColor White
Write-Host ""
Read-Host "Press Enter to exit"
exit 1
}
}
else {
Write-Host "[!] Still not running as Administrator after restart attempt" -ForegroundColor Red
Write-Host "Please manually run PowerShell as Administrator and try again." -ForegroundColor Yellow
Read-Host "Press Enter to exit"
exit 1
}
}
}
Write-Host "[OK] Running with appropriate privileges" -ForegroundColor Green
Write-Host ""
Write-Host "Starting Cursor Free VIP..." -ForegroundColor Cyan
Write-Host ""
# Change to script directory
Set-Location $PSScriptRoot
# Check if virtual environment exists
if (-not (Test-Path ".\myenv\Scripts\python.exe")) {
Write-Host "[!] Virtual environment not found at .\myenv\Scripts\python.exe" -ForegroundColor Red
Write-Host "Please ensure the virtual environment is set up correctly." -ForegroundColor Yellow
Read-Host "Press Enter to exit"
exit 1
}
# Run the application
try {
& ".\myenv\Scripts\python.exe" "main.py"
$exitCode = $LASTEXITCODE
Write-Host ""
if ($exitCode -eq 0) {
Write-Host "Application completed successfully." -ForegroundColor Green
}
else {
Write-Host "Application exited with code: $exitCode" -ForegroundColor Yellow
}
}
catch {
Write-Host "Error running application: $_" -ForegroundColor Red
}
Write-Host ""
Read-Host "Press Enter to exit"

View File

@@ -39,7 +39,7 @@ get_downloads_dir() {
# Get latest version
get_latest_version() {
echo -e "${CYAN} Checking latest version...${NC}"
latest_release=$(curl -s https://api.github.com/repos/yeongpin/cursor-free-vip/releases/latest) || {
latest_release=$(curl -s https://api.github.com/repos/psipher/cursor-free-vip-main/releases/latest) || {
echo -e "${RED}❌ Cannot get latest version information${NC}"
exit 1
}