properly expand homedir