Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^3: Getting the absolute path of a script, without PWD

by Tux (Canon)
on Jul 15, 2021 at 14:48 UTC ( [id://11135034] : note . print w/replies, xml ) Need Help??


in reply to Re^2: Getting the absolute path of a script, without PWD
in thread Getting the shell's version of working directory, without PWD's help

Find the symlinks and build a reverse hash lookup-table.


Enjoy, Have FUN! H.Merijn
  • Comment on Re^3: Getting the absolute path of a script, without PWD

Replies are listed 'Best First'.
Re^4: Getting the absolute path of a script, without PWD
by perlancar (Hermit) on Jul 16, 2021 at 00:16 UTC
    This will result in a permutation of possible paths. How would you know which path is the correct one?