RE: [Perl-unix-users] String Search

2002-10-19 Thread Vitaly Sinitsin
bject: [Perl-unix-users] String Search Hi there people. I've gotta question.   I've  read a line from a file and asign it to a variable, the variable contains the following CD_ROM=/path/of_cdrom   I want to retrieve the last patern ,  "/path/of_cdrom", a

Re: [Perl-unix-users] String Search

2002-10-18 Thread Henry Wong, ¶À³Ç¼e
have you tried using CPAN module Config::IniFiles ? http://search.cpan.org/author/WADG/Config-IniFiles-2.30/IniFiles.pm otherwise try open (FH, $ARGV[0]); my %config; foreach () { my ($key, $value) = split "=", $_, 2; $config{$key} = $value; } print $config{'CD_ROM'},"\n"; --- Pablo Mora

[Perl-unix-users] String Search

2002-10-18 Thread Pablo Morales
Hi there people. I've gotta question.   I've  read a line from a file and asign it to a variable, the variable contains the following CD_ROM=/path/of_cdrom   I want to retrieve the last patern ,  "/path/of_cdrom", and asign it to a variable How can I do that?   Lotta Thanx