HEYLO,
I am experiencing, to some extent, the mystery regarding the development of the perl script. I wrote a small Perl script using the standard (basic) Perl installation. I have the following setup:
C: \ MyScript \ perl.pl
C: \ MyScript \ Configuration \ config.ini
C: \ MyScript \ output \ output.txt
This is the source of perl.pl:
$config = '/configuration/config.ini';
$conf = Config::IniFiles->new( -file => $config_file );
$output_dir = conf->val('output', 'out_dir');
$output_file = "$output_dir/output.txt";
open (out, ">$output_file") || die ("It not your day mate!");
print out "This is a test...";
close out;
This is the contents of config.ini:
[output]
output_dir = C:\MyScript\output
, , , ($ conf), , . script windows, unix ( - ), , ? script, config.ini. , , :
$config = 'C:\MyScript\configuration\config.ini';
, . , , ? ?
/ .
,
MC
Perlisasinger