Possible Duplicate:
Unziping files in python
How do I extract a zip file with Python's ZipFile module? An example script would be awesome!
Possible Duplicate:
Unziping files in python
How do I extract a zip file with Python's ZipFile module? An example script would be awesome!
import zipfile
archive = zipfile.ZipFile(<path-to-file>)
archive.extractall()
See the docs.
import zipfile
dest_dir = 'C://'
zf_name = 'C://my_zip.zip'
pwd = 'my_zip_password'
with zipfile.Zipfile(zf_name, 'r') as z:
z.exctractall(dest_dir, pwd=pwd)