.files, including ~/.osx — sensible hacker defaults for OS X
Shell Perl JavaScript CSS
Pull request Compare This branch is 149 commits ahead, 483 commits behind mathiasbynens:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


weisjohn's dotfiles ( an unholy merger of Mathia's and Ben Alman's dotfile repos )

Brand new OSX machine awesomeness... when you have nothing...

Install the XCode

bash -c "$(curl -fsSL https://raw.github.com/weisjohn/dotfiles/master/bin/dotfiles)"

Why is this a git repo?

The command to get everything started is ~/bin/dotfiles, and this is my "dotfiles" Git repo.

What, exactly, does the "dotfiles" command do?

It's really not very complicated. When dotfiles is run, it does a few things:

  1. Git is installed if necessary, via APT or Homebrew (which is installed if necessary).
  2. This repo is cloned into the ~/mysrc/dotfiles directory (or updated if it already exists).
  3. Files in init are executed (in alphanumeric order).
  4. Files in copy are copied into ~/.
  5. Files in link are linked into ~/.


  • The backups folder only gets created when necessary. Any files in ~/ that would have been overwritten by copy or link get backed up there.
  • Files in bin are executable shell scripts (~/mysrc/dotfiles/bin is added into the path).
  • Files in source get sourced whenever a new shell is opened (in alphanumeric order)..
  • Files in conf just sit there. If a config file doesn't need to go in ~/, put it in there.
  • Files in caches are cached files, only used by some scripts. This folder will only be created if necessary.




  • You need to be an administrator (for sudo).
  • You need to have installed XCode Command Line Tools, which are available as a separate, optional (and much smaller) download from XCode.
bash -c "$(curl -fsSL https://raw.github.com/weisjohn/dotfiles/master/bin/dotfiles)" && source ~/.bashrc


Using Git and the bootstrap script

You can clone the repository wherever you want. (I like to keep it in ~/Projects/dotfiles, with ~/dotfiles as a symlink.) The bootstrapper script will pull in the latest version and copy the files to your home folder.

git clone https://github.com/weisjohn/dotfiles.git && cd dotfiles && ./bootstrap.sh

To update, cd into your local dotfiles repository and then:


Alternatively, to update while avoiding the confirmation prompt:

./bootstrap.sh -f

Git-free install

To install these dotfiles without Git:

cd; curl -#L https://github.com/weisjohn/dotfiles/tarball/master | tar -xzv --strip-components 1 --exclude={README.md,bootstrap.sh}

To update later on, just run that command again.

Add custom commands without creating a new fork

If ~/.extra exists, it will be sourced along with the other files. You can use this to add a few custom commands without the need to fork this entire repository, or to add commands you don’t want to commit to a public repository.

My ~/.extra looks something like this:

# PATH additions
export PATH="~/bin:$PATH"

Sensible OS X defaults

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



Suggestions/improvements welcome!

Thanks to…