Subject: | -BackslashEscape => 1 problem with \$ |
Hi,
There is a problem with the option BackslashEscape and escaping the $
sign (on Win32 platform):
-----------------------------------------------------
Configuration file:
<my_conf>
foo1 = bar
foo2 = $foo1
bar = this\$is
</my_conf>
-----------------------------------------------------
Perl test script:
#!perl
use strict;
use warnings;
use Data::Dumper;
use Config::General;
my %conf = new Config::General(
-ConfigFile => './test.conf',
-InterPolateVars => 1,
-InterPolateEnv => 1,
-IncludeRelative => 1,
-BackslashEscape => 1,
)->getall();
print Dumper \%conf;
-----------------------------------------------------
Result:
$VAR1 = {
'my_conf' => {
'bar' => 'this',
'foo2' => 'bar',
'foo1' => 'bar'
}
};
-----------------------------------------------------
Result for $conf{my_conf}{bar} should be: "this$is" and not "this".
Thank you and best regards,
Richard Gerber