in reply to global vars
then slurp the values in at the beginning of your program:KEY1=VALUE1 KEY2=VALUE2
If you want %config global just declair it as our instead of my, or pass it around with Exporter.open(F,"conf.ini"); my %config = {}' while(<F>) { (my $key,$value) = split /=/; $config{"$key"} = $value; } close(F);
|
|---|