develooper Front page | perl.beginners | Postings from January 2002

AppConfig module ...need help.

From:
jeff loetel
Date:
January 31, 2002 23:05
Subject:
AppConfig module ...need help.
Message ID:
1012547279.1182.0.camel@cabo
Howdy,
I'm trying to run the AppConfig module, but making a error somewhere, it
should be straight forward but....

At any rate here is the code, followed by the config file followed by
the error.

#code
#!/usr/bin/perl

use AppConfig;

my $file = "/var/tmp/config.txt";

my $config = AppConfig->new();

$config->file($file);

print $config->head();
print "\n";

exit;

#config file (/var/tmp/config.txt)
head = doh!

#error
$ ./appConfig.pl 
/var/tmp/config.txt: No such file or directory
head: no such variable

I've checked permissions and tried different things, like using
$config->get($file);

What am I doing wrong. I installed the Appconfig bundle, and checked
everything is there.

jeffl




nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About