Skip to content

Repository files navigation

Dotfiles

Personal development environment configuration for macOS. Built for a zsh + tmux + neovim workflow.

Quick Start

# Clone the repo
git clone git@github.com:yourusername/dotfiles.git ~/dotfiles
# Install Homebrew packages (formulae + casks via Brewfile)
brew bundle install --file=~/dotfiles/Brewfile
# Symlink configs
ln -sf ~/dotfiles/.zshrc ~/.zshrc
ln -sf ~/dotfiles/.tmux.conf ~/.tmux.conf
ln -sf ~/dotfiles/.gitconfig ~/.gitconfig
ln -sf ~/dotfiles/.gitignore_global ~/.gitignore_global
ln -sf ~/dotfiles/.markdownlint.jsonc ~/.markdownlint.jsonc
ln -sf ~/dotfiles/.config/nvim ~/.config/nvim
ln -sf ~/dotfiles/.config/ghostty ~/.config/ghostty
ln -sf ~/dotfiles/.config/pgcli ~/.config/pgcli
ln -sf ~/dotfiles/.ssh/config ~/.ssh/config
mkdir -p ~/.claude
ln -sf ~/dotfiles/.claude/notify.sh ~/.claude/notify.sh
ln -sf ~/dotfiles/.claude/settings.json ~/.claude/settings.json
# Set up local configs (machine-specific, not tracked)
cp ~/dotfiles/.zshrc.local.example ~/.zshrc.local
cp ~/dotfiles/.ssh/config.local.example ~/.ssh/config.local
chmod 600 ~/.ssh/config.local
# Edit these with your SSH keys, hosts, paths# Set up secrets (API tokens, passwords - not tracked)
cp ~/dotfiles/.secrets.example ~/.secrets
chmod 600 ~/.secrets
# Edit ~/.secrets with your actual values

File Structure

The repo uses a .local pattern to separate shareable configs from machine-specific settings:

FileTrackedPurpose
.zshrcYesGeneric shell config
.zshrc.localNoSSH keys, personal paths, project aliases
.ssh/configYesGeneric SSH settings
.ssh/config.localNoHost definitions with real IPs
.secretsNoAPI tokens, passwords

Shell (Zsh)

Config:.zshrc

Framework & Plugins

Key Aliases

AliasCommandDescription
jzoxideSmart directory jumping
vimnvimNeovim
lzglazygitGit TUI
lzdlazydockerDocker TUI
dcedocker compose execDocker exec shortcut
dcudocker compose upDocker up shortcut
gpohgit push origin HEADQuick push
glopen-Open git remote in browser
nnvim .Open nvim in current dir
tkstmux kill-serverKill tmux
tw-Rename tmux window to current dir
askclaude -p (function)Quick Claude prompt (no quotes)

Custom Functions

  • ask - Quick Claude prompt: ask how to say hello in polish
  • base64pbcopy - Base64 encode file to clipboard
  • gitstrip / gitstripstdin - Convert git SSH URLs to HTTPS

Terminal Multiplexer (Tmux)

Config:.tmux.conf

Keybindings

KeyAction
Ctrl-aPrefix (instead of Ctrl-b)
Ctrl-a cNew window (in current path)
Ctrl-a "Split horizontal (in current path)
Ctrl-a %Split vertical (in current path)
Ctrl-Shift-Left/RightReorder windows
Ctrl-a h/j/k/lNavigate panes
Ctrl-a n/pNext/previous window
Ctrl-a SSend pane to window (prompt)
Ctrl-a JJoin marked pane to current window
Ctrl-a mMark pane (built-in)
Ctrl-a MClear mark (built-in)

Features

  • Mouse support enabled
  • Windows/panes start at index 1
  • 50,000 line history
  • GitHub-inspired color theme
  • Auto-renumber windows
  • Bell notifications: windows with activity highlight in red (passthrough enabled for terminal notifications)

Editor (Neovim)

Config:.config/nvim/

Built on LazyVim distribution.

Theme

Key Plugins

PluginPurpose
lazy.nvimPlugin manager
neo-tree.nvimFile explorer
fzf-luaFuzzy finder
gitsigns.nvimGit integration
git-blame.nvimInline git blame
mason.nvimLSP installer
nvim-treesitterSyntax highlighting
trouble.nvimDiagnostics list
which-key.nvimKeybinding hints
bufferline.nvimBuffer tabs
lualine.nvimStatus line
vim-abolishSmart substitution
vim-surroundSurround text objects

Custom Keymaps

  • d deletes without yanking (use x to cut)
  • Ctrl-k/j increment/decrement numbers
  • <leader>go open file in git browser

Terminal Emulator (Ghostty)

Config:.config/ghostty/config

  • Theme: Dracula
  • Font: FiraCode Nerd Font Mono
  • Features:
    • Option as Alt key (macOS)
    • Reduced scroll speed

Git

Config:.gitconfig

  • Pager:delta - Syntax-highlighted diffs
  • Merge style: diff3 (shows base)
  • Color moved: enabled
  • Global ignore:.gitignore_global via core.excludesFile - macOS, editor, and Claude artifacts ignored in every repo. This repo intentionally tracks .claude/notify.sh and .claude/settings.json (already committed); any new .claude/ file needs git add -f.

Database (pgcli)

Config:.config/pgcli/config

PostgreSQL CLI with:

  • Smart auto-completion
  • Syntax highlighting
  • Destructive command warnings
  • 1000 row limit
  • Keyring password storage

SSH

Config:.ssh/config

Host aliases for quick access (defined in ~/.ssh/config.local):

ssh prod # instead of ssh root@x.x.x.x
ssh staging # project shortcuts

Tasks (just)

Common operations are wrapped in a justfile. Run just to list them.

RecipeAction
just setupFull machine setup (runs macos_setup.sh)
just brew-installInstall everything in the Brewfile
just brew-diffShow drift between installed packages and Brewfile
just updateUpdate and upgrade brew packages
just defaultsApply macOS system defaults (macos_defaults.sh)
just lintRun pre-commit hooks (shellcheck + secret scan)

Pre-commit

pre-commit install enables hooks that run on every commit: shellcheck on the shell scripts, gitleaks to block accidental secret commits, and basic file hygiene. Config in .pre-commit-config.yaml.


Homebrew Packages

Packages are managed with a curated Brewfile (brew bundle). The list is intentional, not a full machine dump - use just brew-diff to see what is installed but untracked before adding it.

CLI Essentials

ToolDescription
batCat with syntax highlighting
ezaModern ls replacement
lsdLSDeluxe - another ls replacement
fdFast find alternative
ripgrepFast grep alternative
fzfFuzzy finder
zoxideSmart cd
tldrSimplified man pages
jqJSON processor
yqYAML processor

Development

ToolDescription
neovimEditor
tmuxTerminal multiplexer
lazygitGit TUI
lazydockerDocker TUI
git-deltaBetter git diffs
ghGitHub CLI
justCommand runner
pre-commitGit hooks framework

Languages & Runtimes

ToolDescription
rbenvRuby version manager
nodeNode.js
pnpmFast npm alternative
goGolang
poetryPython dependency management
pipxPython CLI tools

Infrastructure & DevOps

ToolDescription
opentofuInfrastructure as code
tfenvTerraform/tofu version mgr
ansibleConfiguration management
kubectlKubernetes CLI
k9sKubernetes TUI
helmKubernetes package manager
kamalRails deployment
dockerContainers
diveDocker image explorer

Cloud CLIs

ToolDescription
hcloudHetzner Cloud (in history)
awsAmazon Web Services (in history)
gcloudGoogle Cloud (in history)
herokuHeroku CLI

Security & Networking

ToolDescription
sopsEncrypted secrets
ageEncryption tool
trufflehogSecrets scanner
wpscanWordPress scanner
mitmproxyHTTP proxy
dogDNS lookup
httpstatHTTP timing
nmapNetwork scanner (in history)

Media & Misc

ToolDescription
ffmpegVideo processing
yt-dlpVideo downloader
siliconCode screenshots
asciinemaTerminal recording
tokeiCode statistics
ncduDisk usage analyzer

macOS Apps (Casks)

Productivity

CaskAppDescription
raycastRaycastSpotlight replacement
rectangleRectangleWindow management
alt-tabAltTabWindows-style alt-tab
maccyMaccyClipboard manager
hazeoverHazeOverDistraction dimmer
obsidianObsidianNote-taking

Development

CaskAppDescription
ghosttyGhosttyTerminal emulator
cursorCursorAI code editor
zedZedFast code editor
dockerDockerContainers
beekeeper-studioBeekeeper StudioDatabase GUI
brunoBrunoAPI client
charlesCharlesHTTP proxy/debugger

System & Utilities

CaskAppDescription
statsStatsMenu bar system monitor
monitorcontrolMonitorControlExternal display brightness
betterdisplayBetterDisplayDisplay management
linearmouseLinearMouseMouse customization
hammerspoonHammerspoonmacOS automation
the-unarchiverThe UnarchiverArchive extraction
kekaKekaFile archiver
flameshotFlameshotScreenshots

Media

CaskAppDescription
iinaIINAVideo player
vlcVLCMedia player
spotifySpotifyMusic
obsOBSStreaming/recording
cogCogAudio player
eqmaceqMacSystem equalizer
audacityAudacityAudio editor
calibreCalibreE-book manager

Communication

CaskAppDescription
telegramTelegramMessaging
signalSignalSecure messaging

Browsers

CaskAppDescription
google-chromeGoogle ChromeChrome browser
firefoxFirefoxFirefox browser

Security & Network

CaskAppDescription
bitwardenBitwardenPassword manager
nordvpnNordVPNVPN
wiresharkWiresharkNetwork analyzer
cyberduckCyberduckFTP/cloud client
ngrokngrokLocalhost tunneling

Other

CaskAppDescription
ankiAnkiFlashcards
fluxf.luxBlue light filter
stretchlyStretchlyBreak reminder
qbittorrentqBittorrentTorrent client
bambu-studioBambu Studio3D printing slicer
cooltermCoolTermSerial terminal
flowvisionFlowVisionImage browser
claudeClaudeAI assistant

Manual Install

AppDescription
WallyZSA keyboard firmware tool (not in Homebrew)

Secrets & Local Configuration

This repo uses a .local pattern to keep sensitive/machine-specific data out of version control:

FileTemplateContains
~/.secrets.secrets.exampleAPI tokens, passwords
~/.zshrc.local.zshrc.local.exampleSSH keys, personal paths, project aliases
~/.ssh/config.local.ssh/config.local.exampleHost definitions with real IPs
# Set up local files from templates
cp .secrets.example ~/.secrets && chmod 600 ~/.secrets
cp .zshrc.local.example ~/.zshrc.local
cp .ssh/config.local.example ~/.ssh/config.local && chmod 600 ~/.ssh/config.local
# Edit each with your values
nvim ~/.secrets ~/.zshrc.local ~/.ssh/config.local

Hammerspoon

Config:.hammerspoon/

Lua-based macOS automation:

  • lgtv - LG TV control integration

Claude Code

Config:.claude/

Claude Code CLI configuration with smart notifications.

Features

  • Always thinking enabled for extended reasoning
  • Notification hooks - alerts when Claude needs input or completes a task
  • Smart notification suppression - no alerts when actively viewing the tmux pane
  • Terminal bell integration - tmux status bar highlights on activity (works with tmux bell settings above)

Hooks

EventSoundTrigger
NotificationPingClaude needs your input
StopFunkTask completed

Dependencies

  • terminal-notifier - macOS notifications (brew install terminal-notifier)

File Structure

dotfiles/
├── .claude/ # Claude Code config & hooks
├── .config/
│ ├── ghostty/ # Terminal config
│ ├── nvim/ # Neovim (LazyVim)
│ └── pgcli/ # PostgreSQL CLI
├── .github/workflows/ # CI (shellcheck + Brewfile check)
├── .hammerspoon/ # macOS automation
├── .ssh/
│ ├── config # Generic SSH settings (tracked)
│ └── config.local.example # Template for hosts (tracked)
├── .editorconfig # Editor formatting rules
├── .gitconfig # Git config
├── .gitignore # Repo ignores
├── .gitignore_global # Global ignore (core.excludesFile)
├── .pre-commit-config.yaml # Lint + secret-scan hooks
├── .secrets.example # Secrets template
├── .tmux.conf # Tmux config
├── .zshrc # Shell config (tracked)
├── .zshrc.local.example # Template for local settings (tracked)
├── Brewfile # Curated brew formulae + casks (brew bundle)
├── justfile # Task runner recipes
├── macos_setup.sh # Full setup script
├── macos_defaults.sh # macOS system defaults (opt-in)
├── export_local.sh # Export local configs for migration
├── import_local.sh # Import local configs on new machine
└── README.md # This file
# Not tracked (create from .example files):
~/.zshrc.local # SSH keys, personal paths
~/.ssh/config.local # Host definitions with IPs
~/.secrets # API tokens, passwords

New Machine Setup

  1. Install Xcode CLI tools: xcode-select --install
  2. Install Homebrew: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  3. Clone this repo: git clone git@github.com:yourusername/dotfiles.git ~/dotfiles
  4. Run setup: cd ~/dotfiles && ./macos_setup.sh
  5. Import local configs (see below) or customize from .example files
  6. Restart terminal or source ~/.zshrc

Migrating Local Configs

Transfer your local configs (secrets, SSH hosts, etc.) between machines. Archives are encrypted with age using a passphrase.

On the old machine

cd~/dotfiles
./export_local.sh
# Enter a passphrase when prompted# Creates: ~/dotfiles_local_YYYYMMDD_HHMMSS.tar.gz.age

Transfer the archive

# Via SSH
scp ~/dotfiles_local_*.tar.gz.age newmachine:~/
# Or via AirDrop, USB, etc. (encrypted, safe to transfer)

On the new machine

# After running macos_setup.shcd~/dotfiles
./import_local.sh ~/dotfiles_local_*.tar.gz.age
# Enter the same passphrase# Delete the archive
rm ~/dotfiles_local_*.tar.gz.age

What's included

FileContents
.secretsAPI tokens, passwords
.zshrc.localSSH keys to load, personal paths
.ssh/config.localSSH host definitions
.gitconfig.localGit name/email

About

My tmux, zsh, alacritty configs, homebrew list and migration scripts

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages