hello
I trying to modify file using perl one line like below.
my $cmd = "perl -pi -e's/aaa/bbb/' ";
open(MAKEFILES, '<', $ARGV[0]) or die "file open error";
my @filelist = <MAKEFILES>;
foreach my $file (@filelist) {
chomp($file);
my $command = $cmd.$file;
print $command,"\n";
!system($command) or die "shell command not work";
}
close(MAKEFILES);
but system function does not work.
It print
./Windowset/Common/Makefile.gmk
perl -pi -e's/-+g -+dwarf2//' ./Windowset/Common/Makefile.gmk
: No such file or directory.mmon/Makefile.gmk
./Windowset/Special/Makefile.gmk
perl -pi -e's/-+g -+dwarf2//' ./Windowset/Special/Makefile.gmk
: No such file or directory.cial/Makefile.gmk
someone who meet this problem?
Thanks in advance
--
CashFlow
To be rich.
_______________________________________________
Perl-Win32-Users mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs