add resolvePath() to fix bug with ~, issue #120

Fixes https://github.com/rvagg/node-levelup/issues/120