using expanduser to expand ~