title: How to copy directory recursively in python and overwrite all?
body: <p>I'm trying to copy <code>/home/myUser/dir1/</code> and all its contents (and their contents, etc.) to <code>/home/myuser/dir2/</code> in python. Furthermore, I want the copy to overwrite everything in <code>dir2/</code>.</p>
  
  <p>It <em>looks</em> like <code>distutils.dir_util.copy_tree</code> might be the right tool for the job, but not sure if there's anything easier/more obvious to use for such a simple task.</p>
  
  <p>If it is the right tool, how do I use it? According to the <a href="http://docs.python.org/distutils/apiref.html">docs</a> there are 8 parameters that it takes. Do I have to pass all 8 are just <code>src</code>, <code>dst</code> and <code>update</code>, and if so, how (I'm brand new to Python).</p>
  
  <p>If there's something out there that's better, can someone give me an example and point me in the right direction? Thanks in advance!</p>