Python makes working with individual files easy thanks to pathlib, but did you know you can mass copy files with the shutil package?
In this video, we'll dive deep into Python's shutil package, which can be found in the standard library, covering moving, copying, deleting and even archiving!
To run the code, simply install the requirements (pytest
) and run the tests:
cd 009-shutil-deep-dive
pip install -r requirements.txt
pytest
If you'd like to run the archive example, just point the script at the directory you'd like to archive:
cd 009-shutil-deep-dive
python archive.py ./my-test-dir