expand: expand tilde to canonical paths

Work on #1133.
prompt_pwd: Use tilde expansion to get real full home path

Closes #1133.