[Israel.pm] Cwd::abs_path and "~"
Offer Kaye
oferk at oren.co.il
Wed Feb 11 06:24:43 PST 2004
Hi,
I'm trying to pass a path containing the tilda "~" sign in the beginning to
Cwd's abs_path fuction, but I get back undef instead of the full path:
use Cwd qw(abs_path);
my $full_path = abs_path("~/some/path") or die "Couldn't resolve path\n";
I'm running perl 5.8.0 under Linux. Does anybody know why this is failing?
P.S., I don't need a workaround, there are many ways to go around this
problem, I'm just curious as to why this doesn't work. Nothing in Cwd's
documentation suggests this should fail.
Thanks,
----------------------------------
Offer Kaye
More information about the Perl
mailing list