Subject: | conf files not being found on windows xp |
App::Options is not finding app.conf in the prog directory. I have 32 bit Windows XP on two machines. Perl on one is 5.8.9. Perl on the other is 5.10.1. The install of App::Options went smoothly. All tests passed.
Directory of C:\ctemp
01/07/2010 10:17 AM 50 app.conf
01/07/2010 10:23 AM 802 appOptions01.pl
As you see from the paste below, the options from the app.conf file are not being printed out.
--------Paste of results
C:\ctemp>perl appOptions01.pl
Wow. Here are the options...
app => appOptions01
host => T43-2
hostname => T43-2
prefix => C:/Perl
Home is C:\Documents and Settings\Malcolm
EXISTS : C:\ctemp\app.conf!!!
Directory of C:\ctemp
01/07/2010 10:17 AM 50 app.conf
01/07/2010 10:23 AM 802 appOptions01.pl
As you see from the paste below, the options from the app.conf file are not being printed out.
--------Paste of results
C:\ctemp>perl appOptions01.pl
Wow. Here are the options...
app => appOptions01
host => T43-2
hostname => T43-2
prefix => C:/Perl
Home is C:\Documents and Settings\Malcolm
EXISTS : C:\ctemp\app.conf!!!
Subject: | app.conf |
Message body not shown because it is not plain text.
Subject: | appOptions01.pl |
use File::Spec;
$ENV{HOME} = $ENV{"USERPROFILE"};
use App::Options;
print "Wow. Here are the options...\n";
foreach (sort keys %App::options) { # options appear here!
printf("%-20s => %s\n", $_, $App::options{$_});
}
print ("Home is \t\t", $ENV{"USERPROFILE"}, "\n");
my $configFile = File::Spec->catfile("C:", "ctemp", "app.conf");
print "EXISTS : $configFile!!!\n" if (-e("$configFile"));
__END__
>perl appOptions01.pl -s -r -yeah --awake=yes
Wow. Here are the options...
app => appOptions01
awake => yes
host => Biostar01
hostname => Biostar01
prefix => C:/Perl
r => 1
s => 1
yeah => 1
Home is C:\Documents and Settings\Malcolm