This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This is a personal dotfiles repository managed using GNU Stow for macOS and Ubuntu systems. The configuration includes Neovim setups (both nvim and lzvim), shell configurations, terminal emulator settings (Kitty and WezTerm), and development environment tools.
- Root level: Contains platform-specific Makefiles and the main bootstrap script
- Module structure: Each tool/application has its own directory (
nvim/,lzvim/,zsh/,kitty/,wezterm/,tmux/) - OS-specific configs:
macos/andubuntu/directories contain platform-specific scripts and Makefiles - Stow integration: Each module directory contains the actual config files that get symlinked to their target locations
- nvim/: Basic Neovim configuration with Lua-based setup (
config/andplugins/subdirs) - lzvim/: Enhanced Neovim setup with additional plugins including Copilot integration
- bootstrap.sh: Source-safe script that creates directories and installs essential tools (
bat,ripgrep,stow) - Platform Makefiles: Different stow targets for macOS vs Ubuntu systems
git clone https://github.com/tdhuan/dotfiles.git && cd dotfiles && source bootstrap.sh && make allmake all # Stow lzvim, nvim, kitty configs to ~/.config, wezterm and zsh to home
make delete # Remove all symlinkscd ubuntu && make create # Stow lzvim, kitty to ~/.config, wezterm, zsh, tmux to home
cd ubuntu && make delete # Remove Ubuntu symlinks
bash ubuntu/bootstrap.sh # Install bat via apt- Launch
nvimand verify plugins load correctly - Start new Zsh session to test aliases and themes
- Open Kitty to verify configuration is applied
- Open WezTerm to verify
.wezterm.luais loaded from home directory - Test stow operations with dry run:
stow -n -t ~ zsh
- Shell scripts: Use
bashwithset -euo pipefail, prefer functions, 2-space indentation - Lua (Neovim): Format with
styluausing thestylua.tomlfiles in each Neovim directory:- Indent: 2 spaces
- Column width: 120 characters
- Directory naming: lowercase, OS-specific configs in
macos/orubuntu/
- Dotfiles within module folders keep their leading dot (e.g.,
zsh/.zshrc,wezterm/.wezterm.lua) - Each Neovim config (
nvim/,lzvim/) has separatelua/config/andlua/plugins/directories - WezTerm config follows official docs:
.wezterm.luain home directory (not.config/wezterm/) - Platform-specific bootstrapping handled in dedicated OS directories
- Never commit secrets or tokens
- Review shell scripts before execution as they modify system defaults
- Test configurations in safe environments before applying to main system
AGENTS.md: Contains comprehensive repository guidelines including build commands, coding style, and testing proceduresbootstrap.sh: Creates essential directories and installs core tools via Homebrew/aptstylua.toml: Lua formatting configuration (present in both nvim dirs)- Platform-specific Makefiles with different stow targets for macOS vs Ubuntu