Link to home
Start Free TrialLog in
Avatar of Marketing_Insists
Marketing_Insists

asked on

get script's directory location ala $0


If $0 gives the location of the script, how can I get the directory the script is located?

CWD; doesn't work the I want, since if I execute a script located on a network drive from the commandline on my local PC, the working directory would be whatever directory I'm in at my shell.


ASKER CERTIFIED SOLUTION
Avatar of brettmjohnson
brettmjohnson
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Marketing_Insists
Marketing_Insists

ASKER

Sorry, somehow posted to wrong group :)