Real user $HOME dir

Instead of /home/$(whoami), try with:
$(getent passwd $UID | cut -d ':' -f 6)

2 Likes