SPUG: finding full path to itself
Colin Meyer
cmeyer at helvella.org
Tue May 30 16:21:44 PDT 2006
On Tue, May 30, 2006 at 05:40:05PM -0500, jlb wrote:
> Cwd.pm provides some portable, safe methods to determine your current
> working directory.
Or see FindBin.pm, if you want to know where the script itself is
located (e.g. to be able to read a config file from the same dir).
-Colin.
>
> On Tue, 30 May 2006, Satish Gupta wrote:
>
> > When I a stand-alone script is running, how can this script determine it's own absolute path in a portable manner?
> >
> > I notice that $0 works differently on different OS's. On some it gives full path and not on others.
> >
> > Thanks
> >
> >
> > ---------------------------------
> > Be a chatter box. Enjoy free PC-to-PC calls with Yahoo! Messenger with Voice.
> _____________________________________________________________
> Seattle Perl Users Group Mailing List
> POST TO: spug-list at pm.org
> SUBSCRIPTION: http://mail.pm.org/mailman/listinfo/spug-list
> MEETINGS: 3rd Tuesdays
> WEB PAGE: http://seattleperl.org/
More information about the spug-list
mailing list