Cursor Installer is a CLI tool designed to streamline the installation of the Cursor editor on Linux systems. It provides a user-friendly interface for downloading, installing, and managing the Cursor editor, handling everything from desktop integration to version management.
To install Cursor Installer, you need to have Go installed on your system. Then, you can use the following command:
go install github.com/lutefd/cursor-installer@latest
Alternatively, you can clone the repository and build it manually:
git clone https://github.com/lutefd/cursor-installer.git
cd cursor-installer
go build .
Cursor Installer provides both standard and download-only installation modes.
cursor-installer [flags]
You can use the following flags:
Flags:
-d, --download-only
: Only download Cursor without installing-f, --force
: Force installation even if Cursor is already installed-v, --version
: Display version information-h, --help
: Display help for cursor-installer-c, --configure
: Configure Cursor settings after installation
To download without installing:
cursor-installer --download-only
Or
cursor-installer -d
To check the version of both Cursor and the installer:
cursor-installer --version
Or
cursor-installer -v
- Interactive installation progress UI
- Version management and updates
- Desktop integration
- System-wide installation in
/opt
- Automatic desktop entry creation
- Command-line accessibility via symlink
- Update checking and version tracking
- Force installation option for reinstalls
- Download-only mode for manual installations
The project is organized as follows:
cursor-installer/
├── cmd/
│ └── cursor-installer/
│ └── main.go
├── internal/
│ ├── app/
│ │ ├── app.go # Core installer functionality
│ │ ├── desktop.go # Desktop integration
│ │ ├── files.go # File operations
│ │ ├── metadata.go # Installation metadata
│ │ ├── update.go # Update checking
│ │ └── version.go # Version information
│ ├── cli/
│ │ └── cli.go # CLI command handling
│ └── ui/
│ ├── messages.go # Message types and errors
│ ├── model.go # Model types and constructors
│ ├── steps.go # Step handling logic
│ ├── styles.go # UI styles
│ ├── ui.go # Main UI package
│ ├── update.go # Model update logic
│ └── view.go # Model view logic
├── .gitignore
├── go.mod
├── go.sum
├── LICENSE
└── README.md
cmd/cursor-installer
: Contains the main entry point of the applicationinternal/app
: Implements core installation functionality and metadata managementinternal/cli
: Handles command-line interface using Cobrainternal/ui
: Implements the interactive UI using Bubble Tea- Organized into logical components for better maintainability
- Organized into logical components for better maintainability
- Separates concerns between model, view, and update logic
- Centralizes styles and message types
- Separates concerns between model, view, and update logic
- Centralizes styles and message types
To set up the development environment, follow these steps:
-
Clone the repository:
git clone https://github.com/lutefd/cursor-installer.git cd cursor-installer
-
Install dependencies:
go mod download
-
Build the project:
go build .
- Go 1.23.1 or later
- Linux operating system
- Root privileges (for installation)
Contributions to Cursor Installer are welcome! Here are some ways you can contribute:
- Report bugs or request features by opening an issue
- Improve documentation
- Submit pull requests with bug fixes or new features
Please ensure that your code adheres to the existing style and includes appropriate tests before submitting a pull request.
Cursor Installer is open-source software licensed under the MIT license. See the LICENSE file for more details.