use Dir.home for ruby 1.9+

Nice refactor. +1!