Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

915 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hadees’ dotfiles

Managed with chezmoi. One repo targets macOS, Linux, WSL, and disposable remote boxes; a machine class chosen at init time (mac / linux / wsl / ephemeral) controls what gets deployed.

Installation

Warning: If you want to give these dotfiles a try, you should first fork this repository, review the code, and remove things you don’t want or need. Don’t blindly use my settings unless you know what that entails. Use at your own risk!

Fresh machine (one-liner, no root needed)

sh -c "$(curl -fsLS get.chezmoi.io)" -- init --apply hadees

Installs chezmoi to ~/.local/bin, clones this repo, prompts once for the machine class, and applies.

Disposable box (leave no trace)

sh -c "$(curl -fsLS get.chezmoi.io)" -- init --one-shot hadees

Applies the dotfiles, then removes chezmoi, its source clone, and its config from the machine. Answer ephemeral to the machine-class prompt: that class deploys shell config only — no git identity and no secrets ever touch disk. For commit signing on a box you keep around, forward your local 1Password SSH agent (per-host ForwardAgent yes) instead of putting keys there.

Development clone (macOS)

brew install chezmoi
git clone git@github.com:hadees/dotfiles.git ~/code/dotfiles
chezmoi init --source ~/code/dotfiles --apply

The mac machine class pins chezmoi’s sourceDir to the clone, so the day-to-day loop is: edit files in ~/code/dotfiles, review with chezmoi diff, deploy with chezmoi apply (aliased to dotfiles).

Specify the $PATH

If ~/.path exists, it will be sourced along with the other files, before any feature testing (such as detecting which version of ls is being used) takes place.

Here’s an example ~/.path file that adds /usr/local/bin to the $PATH:

export PATH="/usr/local/bin:$PATH"

Add custom commands without creating a new fork

If ~/.extra exists, it will be sourced along with the other files. On managed machines it is rendered by chezmoi from private_dot_extra.tmpl, which pulls secret values out of 1Password at apply time — see CLAUDE.md “Machine-local secrets” for the syntax. On the ephemeral machine class it is never deployed at all.

You could also use ~/.extra to override settings, functions and aliases from my dotfiles repository. It’s probably better to fork this repository instead, though.

Sensible macOS defaults

When setting up a new Mac, you may want to set some sensible macOS defaults:

./.macos

To keep separate machine names, export COMPUTER_NAME before running the script, e.g. COMPUTER_NAME="Work-Mac" ./.macos. If the variable is not set, the existing system name is left unchanged so each Mac can keep its own identity.

Install Homebrew formulae

When setting up a new Mac, you may want to install some common Homebrew formulae (after installing Homebrew, of course):

brew bundle

Feedback

Suggestions/improvements welcome!

Thanks to…

About

.files, including ~/.osx — sensible hacker defaults for OS X

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages