0

I have a Perl code and i want to introduce my input files by regex. I have several files that start with CD* and I want to have an action on each file (The action is converting each file in an XML format) My Perl works fine for one specific file, which I address my input file by full name. Now my Questions are:

Firstly I don't know how to introduce my files as regex in Perl? with the below introduction, I get an error.

$filename=~ /^CD*/i

and secondly, how to save each file? I want to have my bash code on each input file and have a separate output for each input?

Best Regards, Sara

Wiktor Stribiżew
  • 607,720
  • 39
  • 448
  • 563

0 Answers0