Open sourcing this blog. Code on GitHub

I've tidied up the code for this site and decided to open source it if anyone is interested. ...

Rails 3 full page caching on Heroku

Recently I implemented full page caching on this blog. Not because of the insane amount of traffi...

Tuesday, November 27, 2012
Getting rid of .DS_Store files in your git repository

One thing that really bugs me is seeing a repository full of .DS_Store files. I am an offender myself, but now it's time to put an end to this tragedy. The .DS_Store file is a OS X proprietary format for storing information about the folder such as where the icons are placed, the background image etc.

When you run git init it should automatically create a .gitignore file and mark these files as evil!


Add the following to your .gitignore file (if you don't have one yet you can run touch .gitignore):


Run the following in your git repository root:

find . -name ".DS_Store" -depth -exec rm {} \;

Now just commit your changes, and although they might show up again locally they will never be committed to the repository again.

Tweet this post if you found it useful