Sharing Python code via pypi packages - example: common Python utils bundled as 'cornsnake'

To avoid copy-paste hell, (duplicate code is generally regarded to be correlated with bugs) - Python code can be shared via packages.

There is a really nice tutorial here, with just enough detail to walk you through building and publishing your own package:

https://realpython.com/pypi-publish-python-package/

For an example with scripts to automatically bump versions and re-deploy, see:

https://github.com/mrseanryan/cornsnake

cornsnake is a small Python package published via pypi - it contains higher-level wrappers for common Python tasks:

- for working with files, git, ZIP, lists, processes, dates and times.

Comments