About Custom Zipping

To archive a Python module on macOS excluding OS-specific files and Python bytecode, you can use the zip command in the Terminal:

1
2
$ zip -r my_python_module.zip my_python_module \
-x "*.DS_Store" -x "*.pyc" -x "__pycache__"

Tips and Tricks Dev Ops Bash