title: Launch a shell command with in a python script, wait for the termination and return to the script
body: <p>I've a python script that has to launch a shell command for every file in a dir:</p>
  
  <pre><code>import os
  
  files = os.listdir(".")
  for f in files:
      os.execlp("myscript", "myscript", f)
  </code></pre>
  
  <p>This works fine for the first file, but after the "myscript" command has ended, the execution stops and does not come back to the python script.</p>
  
  <p>How can I do? Do I have to <code>fork()</code> before <code>calling os.execlp()</code>?</p>