Cache homedir between invocations.

The homedir of a user doesn't change anyway. Massively speeds up the
case where $HOME isn't set.

Before: BenchmarkDir    1000         2571286 ns/op
After:  BenchmarkDir    1000000000   2.77 ns/op