A modular, extensible dotfiles management system with support for symlinks, package installation, and cross-platform compatibility.
- 🔗 Symlink Management: Automatically create symlinks for your dotfiles with backup support
- 📦 Package Installation: Install packages across different platforms (macOS, Linux)
- 🔄 Backup System: Automatic backup of existing files before replacement
- 🎯 Selective Installation: Choose what to install with interactive prompts
- 🏃 Dry Run Mode: Preview changes before applying them
- 🔧 Extensible: Easy to add new dotfiles and packages via YAML configuration
# Clone the repository
git clone https://github.com/BfdCampos/dotfiles.git
cd dotfiles
# Install Python dependencies
pip install -r requirements.txt
# Run interactive setup
./setup.py
# Or run non-interactive setup (accept all)
./setup.py --yes
# Preview changes without applying
./setup.py --dry-run
# Full interactive setup
./setup.py
# Non-interactive mode (accept all prompts)
./setup.py --yes
# Preview mode (no changes made)
./setup.py --dry-run
# Only create symlinks
./setup.py --only-symlinks
# Only install packages
./setup.py --only-packages
# Force overwrite without backup
./setup.py --force
# Use custom configuration
./setup.py --config my-config.yaml
Define which files to symlink:
symlinks:
- source: bashrc
destination: ~/.bashrc
description: "Bash configuration"
- source: init.vim
destination: ~/.config/nvim/init.vim
description: "Neovim configuration"
create_parent: true # Create parent directories if needed
optional: true # Ask user before creating
Define packages to install:
packages:
neovim:
description: "Hyperextensible Vim-based text editor"
optional: true
installers:
darwin:
method: homebrew
package: neovim
linux:
method: apt
package: neovim
dotfiles/
├── config/ # Configuration files
│ ├── dotfiles.yaml # Symlink definitions
│ └── packages.yaml # Package definitions
├── lib/ # Core modules
│ ├── backup.py # Backup management
│ ├── installers.py # Package installation
│ ├── symlinks.py # Symlink management
│ └── utils.py # Utility functions
├── setup.py # Main setup script
├── bashrc # Bash configuration
├── zshrc # Zsh configuration
├── init.vim # Neovim configuration
└── ... # Other dotfiles
- Add your dotfile to the repository
- Edit
config/dotfiles.yaml
:- source: my-config-file destination: ~/.config/myapp/config description: "My app configuration" create_parent: true
- Run
./setup.py
to create the symlink
The original create_symlinks.py
script is still available for reference but is replaced by the new modular system.