Skip to content

ssoriche/dotfiles

Repository files navigation

Personal Dotfiles

A comprehensive dotfiles configuration managed with chezmoi, featuring automated setup for development environments including Cursor, VSCode, terminal configurations, and various development tools.

Overview

This repository contains my personal dotfiles and configuration files for:

  • Editors: Cursor, VSCode/VSCodium, Neovim
  • Terminal: Fish shell, Wezterm, Ghostty
  • Development Tools: Git, Atuin, Bat, K9s
  • Window Management: Aerospace, Hammerspoon, Karabiner
  • Package Management: Devbox (Nix-based)
  • AI Development: Cursor rules for enhanced coding assistance

Quick Start

Prerequisites

  • chezmoi - Dotfiles manager
  • macOS (primary target platform)

Installation

  1. Install chezmoi (if not already installed):

    sh -c "$(curl -fsLS get.chezmoi.io)"
  2. Initialize with this repository:

    chezmoi init --apply https://github.com/USERNAME/dotfiles.git
  3. Apply configurations:

    chezmoi apply

Cursor & VSCode Configuration

Settings Management

This dotfiles setup uses a modular approach to manage Cursor and VSCode settings:

Architecture Note: The vscode-settings/ directory is located at the repository root (not in private_dot_config/) because it contains management tools and source files that should not be deployed by chezmoi. The actual settings are deployed via templates to the proper editor locations.

Settings Structure

vscode-settings/
├── 01-base.json          # Core editor settings
├── 02-vim.json           # Vim keybindings and behavior
├── 03-navigation.json    # File navigation and search
├── 03-theme.json         # UI theme and appearance
├── 04-languages.json     # Language-specific settings
├── 05-keybindings.json   # Custom keybindings
├── 06-whichkey.json      # Which-key menu configuration
├── 99-overrides.json     # Final overrides
└── bin/
    ├── manage-vscode-settings.fish
    └── vscode-manager-aliases.fish

Managing Settings

The settings are automatically merged and applied using the management script:

# Apply settings to specific editor
vscode-settings/bin/manage-vscode-settings.fish apply cursor
vscode-settings/bin/manage-vscode-settings.fish apply codium

# Apply settings to all editors
vscode-settings/bin/manage-vscode-settings.fish apply all

# Show differences before applying
vscode-settings/bin/manage-vscode-settings.fish diff cursor
vscode-settings/bin/manage-vscode-settings.fish diff all

Extension Management

Extensions are managed through text files that list required extensions:

vscode-settings/
├── cursor-extensions.txt        # Cursor-specific extensions
├── codium-extensions.txt        # VSCodium-specific extensions
├── shared-extensions.txt        # Extensions for both editors
├── cursor-global-rules.txt      # Legacy global Cursor rules
└── cursorrules-template.txt     # Project-specific rules template

Installing Extensions

The management script provides convenient commands for extension installation:

# Install extensions for specific editor
vscode-settings/bin/manage-vscode-settings.fish install-extensions cursor
vscode-settings/bin/manage-vscode-settings.fish install-extensions codium

# Install extensions for all editors
vscode-settings/bin/manage-vscode-settings.fish install-extensions all

# Sync extensions (install missing, keep existing)
vscode-settings/bin/manage-vscode-settings.fish sync-extensions cursor
vscode-settings/bin/manage-vscode-settings.fish sync-extensions all

Cursor Rules

AI-powered development assistance through Cursor rules:

private_dot_config/cursor/rules/
├── core/
│   └── personal-preferences.mdc # Personal development environment and workflow preferences
└── development/
    └── coding-standards.mdc     # General coding standards and best practices

Cursor Rules Features

  • Personal Preferences: Development environment setup, code style preferences, and workflow guidelines
  • Coding Standards: Best practices for code quality, function design, performance, and security
  • Modular Structure: Rules organized by category with frontmatter configuration for conditional application

Key Features

Development Environment

  • Unified Settings: Consistent configuration across Cursor and VSCode
  • Modular Configuration: Easy to customize individual aspects
  • Extension Sync: Automated extension installation and management
  • AI Enhancement: Cursor rules for improved coding assistance

Terminal Setup

  • Fish Shell: Modern shell with intelligent autocompletion
  • Wezterm/Ghostty: GPU-accelerated terminal emulators
  • Atuin: Enhanced shell history with sync capabilities
  • Bat: Syntax-highlighted cat replacement

Window Management

  • Aerospace: Tiling window manager for macOS
  • Hammerspoon: Lua-based automation and window management
  • Karabiner: Advanced keyboard customization

Development Tools

  • Git: Comprehensive git configuration with templates
  • Devbox: Nix-based development environment management
  • K9s: Kubernetes cluster management
  • Neovim: Highly configured editor setup

Usage

Managing Dotfiles with chezmoi

# Edit a file
chezmoi edit ~/.config/fish/config.fish

# Apply changes
chezmoi apply

# Add a new file
chezmoi add ~/.new-config-file

# Check status
chezmoi status

# View differences
chezmoi diff

# Update from repository
chezmoi update

Cursor/VSCode Workflow

  1. Settings Updates: Modify JSON files in vscode-settings/
  2. Apply Changes: Run vscode-settings/bin/manage-vscode-settings.fish apply all
  3. Extension Management: Update extension lists and run vscode-settings/bin/manage-vscode-settings.fish sync-extensions all
  4. Cursor Rules: Add new .mdc files to enhance AI assistance, deploy with chezmoi apply ~/.config/cursor/
  5. Complete Setup: Use vscode-settings/bin/manage-vscode-settings.fish setup all for new installations

Adding New Extensions

  1. Add extension ID to appropriate file:

    • shared-extensions.txt for both editors
    • cursor-extensions.txt for Cursor only
    • codium-extensions.txt for VSCodium only
  2. Install the new extensions:

    # Sync extensions (installs any missing extensions)
    vscode-settings/bin/manage-vscode-settings.fish sync-extensions all
    
    # Or install for specific editor
    vscode-settings/bin/manage-vscode-settings.fish install-extensions cursor

Additional Extension Management

The script provides several other useful extension management commands:

# List currently installed extensions
vscode-settings/bin/manage-vscode-settings.fish list-extensions cursor
vscode-settings/bin/manage-vscode-settings.fish list-extensions all

# Export currently installed extensions to a file
vscode-settings/bin/manage-vscode-settings.fish export-extensions cursor

# Complete setup (settings + extensions)
vscode-settings/bin/manage-vscode-settings.fish setup cursor
vscode-settings/bin/manage-vscode-settings.fish setup all

# Check status of all editors
vscode-settings/bin/manage-vscode-settings.fish status

# Cursor Rules Management
vscode-settings/bin/manage-vscode-settings.fish cursor-rules-status  # Show Cursor rules configuration status
vscode-settings/bin/manage-vscode-settings.fish apply-cursor-rules   # Apply global Cursor rules (legacy)
vscode-settings/bin/manage-vscode-settings.fish backup-cursor-rules  # Backup current Cursor rules

Upstream Projects

This configuration builds upon and integrates with several excellent open-source projects:

Core Tools

  • chezmoi - Dotfiles manager
  • Cursor - AI-powered code editor
  • VSCode - Microsoft's code editor
  • Neovim - Hyperextensible Vim-based text editor

Terminal & Shell Tools

  • Fish Shell - Smart and user-friendly command line shell
  • Wezterm - GPU-accelerated terminal emulator
  • Ghostty - Fast, native terminal emulator
  • Atuin - Magical shell history

Development Environment Tools

  • Devbox - Instant, easy, predictable development environments
  • Nix - Purely functional package manager

Window Management Tools

Cursor Rules Resources

Customization

Adding New Configurations

  1. Add files to chezmoi:

    chezmoi add ~/.config/new-tool/config.yaml
  2. Edit with chezmoi:

    chezmoi edit ~/.config/new-tool/config.yaml
  3. Apply changes:

    chezmoi apply

Modifying Cursor Rules

  1. Structured Rules: Create new .mdc files in private_dot_config/cursor/rules/core/ or private_dot_config/cursor/rules/development/

  2. Use the frontmatter format:

    ---
    description: Rule description
    globs:
    alwaysApply: false
    ---
  3. Deploy Rules: Run chezmoi apply ~/.config/cursor/ to deploy changes

  4. Legacy Support: Global rules file and project templates available via vscode-settings/bin/manage-vscode-settings.fish commands

VSCode Settings Customization

  1. Modify the appropriate JSON file in vscode-settings/
  2. Run vscode-settings/bin/manage-vscode-settings.fish to apply changes
  3. Settings are merged in numerical order (01, 02, 03, etc.)

Contributing

While this is a personal dotfiles repository, contributions and suggestions are welcome:

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Submit a pull request with a clear description

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

  • The chezmoi project for excellent dotfiles management
  • The awesome-cursorrules community for AI development enhancements
  • All the upstream projects that make this configuration possible
  • The open-source community for continuous inspiration and improvement

This README is maintained as part of the dotfiles repository for documentation purposes.

About

Configuration of all the command line things.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •