title: How to combine Linux find, convert and copy commands into one command
body: <p>I have the following cmd that fetches all .pdf files with an STP pattern in the filename and places them into a folder:</p>
  
  <pre><code>find /home/OurFiles/Images/ -name '*.pdf' |grep "STP*" | xargs cp -t /home/OurFiles/ImageConvert/STP/
  </code></pre>
  
  <p>I have another cmd that converts pdf to jpg. </p>
  
  <pre><code>find /home/OurFiles/ImageConvert/STP/ -type f -name '*.pdf' -print0 |
    while IFS= read -r -d '' file
      do convert -verbose -density 500 -resize 800 "${file}" "${file%.*}.jpg"
  
      done
  </code></pre>
  
  <p>Is it possible to combine these commands into one? Also, I would like pre-pend a prefix onto the converted image file name in the single command, if possible. Example: STP_OCTOBER.jpg to MSP-STP_OCTOBER.jpg. Any feedback is much appreciated. </p>