pjf / ipc-system-simple

Perl module to make running system commands and capturing errors as simple as possible.
http://search.cpan.org/perldoc?IPC::System::Simple
Other
19 stars 20 forks source link

System simple does not recognise metacharacters #15

Open meganke opened 9 years ago

meganke commented 9 years ago

I'm having problems with using system with metacharacters. I am trying to use system by passing in a single string including a file redirect, ">". I know the same code works on both linux and os x, but on Windows 8.1 using 64 bit strawberry perl 5.20.1.1, the system command fails to recognise the meta-character and split the command.

For Example: system("bwa mem file1 file2 > outputFile") passes ">outputFile" to the bwa executable as a parameter.

jkeenan commented 4 years ago

I'm having problems with using system with metacharacters. I am trying to use system by passing in a single string including a file redirect, ">". I know the same code works on both linux and os x, but on Windows 8.1 using 64 bit strawberry perl 5.20.1.1, the system command fails to recognise the meta-character and split the command.

For Example: system("bwa mem file1 file2 > outputFile") passes ">outputFile" to the bwa executable as a parameter.

Can we assume that, in the example above, bwa and mem are just dummy copy, i.e., not real commands?