1

This is a silly question. I want to apply a "convert ..." operation on a list of files. I have been able to successfully apply it using a find operator:

find $FolderA/ -name "*.dcm" | parallel --will-cite "convert {} -resize %50 $FolderB/{/.}.png"

I want to replicate this command to a specific list of files. I have tried:

parallel "convert $FolderA/{} -resize %50 $FolderB/{/.}.png :::file1 file2 file3...

but it does not work. Parallel just hangs with

parallel: Warning: Input is read from the terminal. Only experts do this on purpose. Press CTRL-D to exit

Any idea what is the right syntax for a list of files?

Eli
  • 81
  • 1
  • 6
  • What you are doing is correct. Is it an old version installed as a package? http://stackoverflow.com/questions/16448887/gnu-parallel-not-working-at-all – Ole Tange Feb 07 '17 at 00:56

1 Answers1

1

This should work for you:

parallel convert "$FolderA/{}" -resize 50% "$FolderB/{/.}.png" ::: file1.dcm file2.dcm
Mark Setchell
  • 191,897
  • 31
  • 273
  • 432