ghenry has asked for the wisdom of the Perl Monks concerning the following question:
Dear Master Monks,
I have been playing with Term::ANSIColor and die, the docs say to use print, but I'd thought I'd try it with die anyway.
For some reason however, in the below code, it seems to always include $!, no matter what I do.
Any tips on how to not include this?
if ($install) { # Open the configfile at /etc/myconf.conf my $Config = Config::Tiny->read( $conf ) if -e $conf or die RED, "\n\nError: Config file $conf missing\n\n", RESET; # Just testing print "Installing now\n"; # Reading properties and print to test my $pgpass = $Config->{Postgresql}->{pass}; print "$pgpass\n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Term::ANSIColor and DIE
by Fletch (Bishop) on May 23, 2005 at 13:14 UTC | |
by ghenry (Vicar) on May 23, 2005 at 13:23 UTC |