Personal dotfiles for macOS and Linux with modular shell functions, git workflows, and kubectl shortcuts.
# Clone and install
git clone https://github.com/yourusername/dotfiles.git ~/workspace/projects/dotfiles
cd ~/workspace/projects/dotfiles
./install.sh
# Or use make
make install./install.sh --minimal # Minimal config for servers/containers
./install.sh --no-packages # Skip package installation
./install.sh --dry-run # Preview what will be installed
# Make targets
make install # Full installation
make install-minimal # Minimal config
make install-no-packages # Config files only
make install-dry-run # Preview changes# One-liner for remote servers
curl -fsSL https://raw.githubusercontent.com/yourusername/dotfiles/main/install.sh | bash -s -- --minimal
# SSH with dotfiles
ssh user@host 'bash -s' < install.sh --minimaldotfiles/
βββ common/ # Cross-platform configurations
β βββ shell/ # Shell configs (.bashrc, .zshrc)
β βββ git/ # Git configuration
β βββ shell-functions/ # Modular functions & aliases
β βββ themes/ # Color themes (Catppuccin)
βββ darwin/ # macOS specific
β βββ Brewfile # Homebrew packages
β βββ kitty.conf # macOS kitty config
βββ linux/ # Linux specific
β βββ debian/ # Ubuntu/Debian packages
β βββ arch/ # Arch Linux packages
β βββ fedora/ # Fedora/RHEL packages
β βββ alpine/ # Alpine Linux packages
βββ install.sh # Universal installer
| File | Installed Location | Description |
|---|---|---|
.bashrc |
~/.bashrc |
Bash configuration with prompt, colors, functions |
.zshrc |
~/.zshrc |
Zsh configuration with Catppuccin theme |
.bash_profile |
~/.bash_profile |
Bash profile (sources .bashrc) |
.bashrc.server |
~/.bashrc |
Conservative bash config for servers (minimal mode) |
.gitconfig |
~/.gitconfig |
Git aliases and fuzzy commands |
.gitignore_global |
~/.config/git/ignore |
Global git ignores |
.gnu_aliases |
~/.gnu_aliases |
GNU coreutils aliases for macOS |
.dircolors |
~/.dircolors |
Directory colors |
kitty.conf |
~/.config/kitty/kitty.conf |
Kitty terminal config |
htoprc |
~/.config/htop/htoprc |
htop configuration |
All shell functions are installed to ~/.config/shell-functions/:
| File | Purpose | Key Commands |
|---|---|---|
kubectl-aliases.sh |
Kubernetes shortcuts | k get p, kgpw, kdp, kshp |
git-aliases.sh |
Git shortcuts | g, gs, gaa, gcm, gp |
git.sh |
Git workflow functions | git-ch(), git-log(), git-add() |
ssh.sh |
SSH helpers | sshdot, sshconf, ssht |
docker.sh |
Docker helpers | dex, dlog, dclean |
utils.sh |
Utilities | mkcd, extract, backup |
fuzzy-vim.sh |
Vim with fzf | v (fuzzy file open) |
git ch # Fuzzy branch checkout with preview
git flog # Interactive commit browser
git fadd # Fuzzy file staging with diff preview
git llog # Fuzzy search through commit history
git st # status
git cm # commit -m
git lg # Pretty log with graph# Quick shortcuts
k # kubectl
kgp # kubectl get pods
kgpw # kubectl get pods -o wide
kdp # kubectl describe pod
klf # kubectl logs -f
# Functions
kshp <pattern> # Shell into first pod matching pattern
klp <pattern> # Logs from first pod matching pattern
kctx # Switch context with fzf
kns # Switch namespace with fzfCore tools: awscli, bash, coreutils, git, fzf, fd, ripgrep, htop, tree, wget
Development: node, python, rust, poetry, virtualenv
Kubernetes: kubernetes-cli, helm, k9s, eksctl, minikube
Infrastructure: terraform, terraformer, tflint
Apps: docker, docker-desktop, slack, spotify
Equivalent packages are automatically installed based on distribution:
- Debian/Ubuntu: Via apt from
linux/debian/packages.list - Arch/Manjaro: Via pacman from
linux/arch/packages.list - Fedora/RHEL: Via dnf/yum from
linux/fedora/packages.list - Alpine: Via apk from
linux/alpine/packages.list
- Catppuccin Mocha color theme
- Git branch and status indicators
- Current directory with smart truncation
- Kubernetes context awareness
- Python virtual environment display
Example prompt:
β [jm@~/projects/dotfiles] main β
- File search:
vto open files with vim - Git branches:
git chfor interactive checkout - Git commits:
git flogto browse history - Git staging:
git faddto stage files - Kubernetes:
kctx/knsfor context/namespace switching
Automatically aliases GNU versions to replace BSD utilities:
lsβglswith colorsgrepβggrepsedβgsed- And more...
The installer automatically backs up existing configs to:
~/.dotfiles-backup-YYYYMMDD_HHMMSS/
To clean old backups (30+ days):
make clean-backupThe installer auto-detects container environments and uses minimal mode:
# In a Docker container
./install.sh # Automatically uses --minimalThe installer automatically detects:
- OS: macOS, Linux (Ubuntu, Debian, Arch, Fedora, Alpine, etc.)
- Environment: Local, SSH session, Docker container
- Shell: Bash, Zsh
- Available tools: Adjusts configs based on what's available
Create ~/.bashrc.local or ~/.zshrc.local for machine-specific configs.
The installer respects CLAUDE.md files for project-specific context.
- macOS: Homebrew (auto-installed if missing)
- Linux: sudo access for package installation
- All systems: Git, Bash 4+
# Check what would be installed
./install.sh --dry-run
# Skip package installation
./install.sh --no-packages
# Force minimal mode
./install.sh --minimal
# View installer help
./install.sh --help