Skip to content

Latest commit

 

History

History
81 lines (60 loc) · 1.62 KB

File metadata and controls

81 lines (60 loc) · 1.62 KB

Publishing to PyPI

This guide explains how to publish the dolphin-utils package to PyPI.

Prerequisites

  1. Install build and upload tools:
pip install build twine
  1. Create accounts on:

Building the Package

Build the distribution files:

python -m build

This creates:

  • dist/dolphin_utils-X.X.X.tar.gz (source distribution)
  • dist/dolphin_utils-X.X.X-py3-none-any.whl (wheel distribution)

Testing on TestPyPI

  1. Upload to TestPyPI first:
python -m twine upload --repository testpypi dist/*
  1. Test installation from TestPyPI:
pip install --index-url https://test.pypi.org/simple/ dolphin-utils
  1. Test the CLI command:
dolphin-summarize --help

Publishing to PyPI

Once testing is successful:

  1. Upload to PyPI:
python -m twine upload dist/*
  1. Verify installation:
pip install dolphin-utils
dolphin-summarize --help

Version Management

Update the version in pyproject.toml before each release:

[project]
name = "dolphin-utils"
version = "0.5.0"  # Increment this

Package Contents

The package provides:

  • Package name: dolphin-utils
  • CLI command: dolphin-summarize
  • Python module: python -m dolphin_summarize
  • Import: import dolphin_summarize

Notes

  • The package name is dolphin-utils (with hyphen)
  • The Python module is dolphin_summarize (with underscore)
  • The CLI command is dolphin-summarize (with hyphen)
  • This follows Python packaging conventions