Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

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

by hippo (Bishop)
on Jul 15, 2021 at 12:28 UTC ( [id://11135027]=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

Sure - there may be some cases where you might want the symlink name rather than the target. But that's not what you've asked. Your question says "... without PWD". Why impose this arbitrary restriction? If you want what $PWD gives, why not just use it?


🦛

  • 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 15, 2021 at 12:34 UTC
    Yes, that's just a curiosity. I'm using PWD right now.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11135027]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (4)
As of 2024-04-24 02:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found