Skip to content

Instantly share code, notes, and snippets.

@hhromic
Last active October 25, 2018 12:48
Show Gist options
  • Save hhromic/5976d882689667574498383e0401fc1d to your computer and use it in GitHub Desktop.
Save hhromic/5976d882689667574498383e0401fc1d to your computer and use it in GitHub Desktop.
Publishing to PyPi

Publishing to PyPi

  1. Update code
  2. Update version number in setup.py or setup.cfg
  3. Commit all changes: git commit -a
  4. Tag the current state with version number: git tag X.Y.Z
  5. Push changes to remote: git push --tags
  6. Build source distribution: python setup.py sdist bdist_wheel
  7. Release to PyPi: twine upload dist/*
  8. Update GitHub release with notes and other stuff

Notes on packaging and publishing: https://packaging.python.org/tutorials/packaging-projects/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment