I have a variable in my bash script whose value is something like this:
~/a/b/c
Note that it is unexpanded tilde. When I do ls -lt on this
How about this:
path=`realpath "$1"`
Or:
path=`readlink -f "$1"`