A specialized dotfiles management system focused exclusively on managing Cursor IDE configurations. This tool helps you maintain consistent Cursor development environments by easily backing up and restoring your .cursor directory and related configuration files across different projects.
# Install UV if you haven't already
curl -LsSf https://astral.sh/uv/install.sh | sh
# Clone the repository
git clone https://github.com/yourusername/dotfiles.git
cd dotfiles
# Create and activate virtual environment with UV
uv venv
source .venv/bin/activate # On Unix/macOS
# or
.venv\Scripts\activate # On Windows
# Install dependencies
uv pip install -e ".[dev]"
# Run the dotfiles command
dotfiles --help
# Backup your Cursor configurations
dotfiles backup ~/projects/myrepo
# List available backups
dotfiles list
# Restore Cursor configurations
dotfiles restore /path/to/target/directory
# Export configurations to a zip file (new feature)
dotfiles backup ~/projects/myrepo --zip-export- Python 3.8 or higher
- Git
- UV package manager
-
Install UV
curl -LsSf https://astral.sh/uv/install.sh | sh -
Create Virtual Environment
uv venv source .venv/bin/activate # Unix/macOS # or .venv\Scripts\activate # Windows
-
Install Dependencies
# Install all dependencies including development tools uv pip install -e ".[dev]"
-
Verify Installation
# Run tests pytest # Check code formatting black --check . isort --check . ruff check . mypy .
# List available backups
dotfiles list [REPO] [--verbose] [--latest]
# Backup Cursor configurations
dotfiles backup REPO_PATH [--branch BRANCH] [--dry-run]
# Restore Cursor configurations
dotfiles restore TARGET_DIR [BACKUP_DIR] [--force] [--dry-run]
# Wipe Cursor configurations
dotfiles wipe REPO_PATH [--force] [--dry-run]# Backup Cursor configurations from a repository
dotfiles backup ~/projects/myrepo
# Backup from a specific branch
dotfiles backup ~/projects/myrepo --branch feature-branch
# Perform a dry run (show what would be backed up without doing it)
dotfiles backup ~/projects/myrepo --dry-run# Restore to a target directory using the latest backup (automatically detected)
dotfiles restore /path/to/target/directory
# Restore from a specific repository to a target directory
dotfiles restore repo-name /path/to/target/directory
# Restore from a specific branch
dotfiles restore repo-name /path/to/target/directory --branch main
# Restore from a specific date
dotfiles restore repo-name /path/to/target/directory --date 20250226
# Force restore over existing files
dotfiles restore repo-name /path/to/target/directory --force
# Perform a dry run (show what would be restored without doing it)
dotfiles restore repo-name /path/to/target/directory --dry-run# List all available backups
dotfiles list
# List backups for a specific repository
dotfiles list myrepo
# Show detailed information about backups
dotfiles list --verbose
# Show only the latest backup for each repository
dotfiles list --latest- Cursor-Focused Management: Specialized handling of
.cursordirectory and related configuration files - Automatic Backup Selection: When restoring, the tool automatically finds and uses the latest backup
- Backup Validation: Validates that all Cursor configuration files are restored correctly
- Branch-Specific Backups: Create and restore backups for specific Git branches
- Dry Run Mode: Preview operations without making changes
- Detailed Progress: Real-time progress indicators for all operations
- Zip Export: Export configurations as a zip file for easy sharing (coming soon)
- Structured Logging: Comprehensive logging with rotation for better debugging
The tool now exclusively manages Cursor IDE configurations:
.cursor/directory - Contains all Cursor-specific configurations including:- Rules
- Settings
- Cache
- Workspace state
- Extensions configuration
The configuration has been simplified to focus on Cursor files. Create or edit ~/.dotfilesrc:
# Global Configuration
search_paths:
- ~/projects
- ~/source
max_depth: 3
exclude_patterns:
- node_modules
- .venvLocal configuration (.dotfilesrc in your repository) is optional and will be automatically configured for Cursor files.
Version 2.0 focuses exclusively on Cursor IDE configurations. If you're upgrading from a previous version:
-
Configuration Updates
- Previous versions managed multiple program configurations
- Now focuses solely on
.cursordirectory and related files - Your existing
.dotfilesrcwill be automatically migrated - Non-Cursor configurations will be ignored
-
Backup Changes
- Previous backups remain compatible
- New backups will only include Cursor-related files
- Use
--zip-exportflag to create shareable backups
-
Command Changes
- All commands now operate only on Cursor files
- Added progress indicators for better visibility
- Enhanced logging for troubleshooting
-
Automatic Migration The tool will automatically:
- Detect and migrate old configuration formats
- Preserve existing backups
- Update to the new cursor-focused structure
For detailed migration assistance, run:
dotfiles doctor --migration-check