kv-clearnup/README.md

68 lines
2.2 KiB
Markdown

# KV Clearnup (Antigravity) 🚀
A modern, high-performance system optimizer for macOS, built with **Electron**, **React**, and **Go**.
![App Screenshot](https://via.placeholder.com/800x500?text=Antigravity+Dashboard)
## Features
- **Flash Clean**: Instantly remove system caches, logs, and trash.
- **Deep Clean**: Scan for large files and heavy folders.
- **Real-time Monitoring**: Track disk usage and category sizes.
- **Universal Binary**: Runs natively on both Apple Silicon (M1/M2/M3) and Intel Macs.
- **High Performance**: Heavy lifting is handled by a compiled Go backend.
## Prerequisites
- **Node.js** (v18+)
- **Go** (v1.20+)
- **pnpm** (preferred) or npm
## Development
### 1. Install Dependencies
```bash
npm install
```
### 2. Run in Development Mode
This starts the Go backend (port 36969) and the Vite/Electron frontend concurrently.
```bash
./start-go.sh
```
*Note: Do not run `npm run dev` directly if you want the backend to work. Use the script.*
## Building for Production
To create a distributable `.dmg` file for macOS:
### 1. Build the App
```bash
npm run build:mac
```
This command will:
1. Compile the Go backend for both `amd64` and `arm64`.
2. Create a universal binary using `lipo`.
3. Build the React frontend.
4. Package the Electron app and bundle the backend.
5. Generate a universal `.dmg`.
### 2. Locate the Installer
The output file will be at:
```
release/KV Clearnup-1.0.0-universal.dmg
```
## Running the App
1. **Mount the DMG**: Double-click the `.dmg` file in the `release` folder.
2. **Install**: Drag the app to your `Applications` folder.
3. **Launch**: Open "KV Clearnup" from Applications.
*Troubleshooting*: If you see "System Extension Blocked" or similar OS warnings, go to **System Settings > Privacy & Security** and allow the application.
## Architecture
- **Frontend**: React, TypeScript, TailwindCSS, Framer Motion.
- **Main Process**: Electron (TypeScript).
- **Backend**: Go (Golang) for file system operations and heavy scanning.
- **Communication**: Electron uses `child_process` to spawn the Go binary. Frontend communicates with backend via HTTP (localhost:36969).
## License
MIT