Dotfiles
Personal configuration files managed with chezmoi, using Nix for packages and Bitwarden for secrets.
⚠️ Warning: Review the code before applying. These are personal configurations—fork and customize for your own
use.
Features
- Cross-platform: NixOS, macOS (nix-darwin), Windows, WSL
- Declarative packages: NixOS/nix-darwin system configs, winget for Windows
- Secrets management: Bitwarden integration for SSH keys and tokens
- Shell frameworks: Zim for Zsh (Unix), Oh My Posh for PowerShell (Windows)
- Development environments: Per-project devenv.nix, LazyVim Neovim setup
Quick Start
Requirements
- Bitwarden account with items using unique, specific names (e.g.,
ssh-key-main not main)
- ⚠️ Limitation: Chezmoi's Bitwarden integration cannot filter by type or folder, only by name with fuzzy matching
- Avoid common words that might match multiple items
One-Line Installation
macOS/NixOS:
curl -sfL https://raw.githubusercontent.com/mariomarin/dotfiles/main/.install/bootstrap-unix.sh | sh
Windows:
iwr -useb https://raw.githubusercontent.com/mariomarin/dotfiles/main/.install/bootstrap-windows.ps1 | iex
Customizing for Your Machine
Chezmoi - edit ~/.config/chezmoi/chezmoi.toml:
[data.machineConfig.features]
kanata = false # Disable keyboard remapping
Nix - username syncs from chezmoi config automatically.
Kanata is disabled by default for unknown machines.
The bootstrap script will:
- Install Nix package manager (macOS only, if not present)
- Clone the repository
- Enter nix-shell environment (Unix) or install tools via winget (Windows)
- Setup Bitwarden and unlock vault
- Prompt for hostname selection
- Initialize chezmoi
- Automatically apply OS-specific system configuration (NixOS/nix-darwin)
After bootstrap completes, your system is fully configured!
Future Updates
# macOS: Update nix-darwin configuration
cd ~/.local/share/chezmoi && just darwin
# NixOS: Update system configuration
cd ~/.local/share/chezmoi && just nixos
# Apply dotfile changes only (no system rebuild)
cd ~/.local/share/chezmoi && just apply
Platform-Specific Details
💡 NixOS
System manages: All packages, services, boot, networking
Update: just nixos
Docs: nix/nixos/README.md
💡 macOS (nix-darwin)
System manages: CLI tools, GUI apps (nixpkgs), Homebrew casks (apps not in nixpkgs)
Update: just darwin
Docs: nix/darwin/README.md
💡 Windows
Packages: Managed via winget (.chezmoidata/packages.yaml)
Development: Use WSL with NixOS for devenv
WSL Setup: wsl/README.md
📖 Detailed installation guide: .install/README.md
Repository Structure
.
├── nix/ # Nix configurations
│ ├── nixos/ # NixOS system configuration
│ ├── darwin/ # macOS (nix-darwin) configuration
│ └── common/ # Shared Nix modules
├── private_dot_config/ # Application configs → ~/.config/
│ ├── nvim/ # Neovim (LazyVim)
│ ├── tmux/ # Tmux configuration
│ ├── zsh/ # Zsh shell configuration
│ ├── zim/ # Zim framework for Zsh
│ └── kanata/ # Keyboard remapping
├── private_dot_local/ # Local data → ~/.local/
│ ├── bin/ # User binaries
│ └── share/ # Shared data
├── docs/ # Documentation
├── wsl/ # WSL-specific setup
└── .chezmoiscripts/ # Scripts run during apply
For chezmoi naming conventions, see the
official documentation.
Documentation
Common Commands
# List all available tasks
just --list
# Apply dotfiles (default)
just
# Preview changes before applying
just diff
# Update everything (system packages, plugins, etc.)
just update
# System operations
just nixos # NixOS rebuild (nix/nixos/switch)
# Component operations
just nvim # Sync Neovim plugins
just tmux # Reload tmux config
just zim # Update Zim modules