Last active
May 28, 2020 20:32
-
-
Save iamkarlson/c9bc2cad7440b8f2ac72b933c29fdba4 to your computer and use it in GitHub Desktop.
unzips files with python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import sys | |
| from zipfile import PyZipFile | |
| for zip_file in sys.argv[1:]: | |
| print("unzipping %s"%zip_file) | |
| pzf = PyZipFile(zip_file) | |
| dir = zip_file.replace('.zip','') | |
| pzf.extractall(dir) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment