Skip to content

TextHumanize 0.31.1 — minimal-mode whitespace fix #28

TextHumanize 0.31.1 — minimal-mode whitespace fix

TextHumanize 0.31.1 — minimal-mode whitespace fix #28

Workflow file for this run

name: Publish to PyPI
on:
release:
types: [published]
workflow_dispatch:
permissions:
contents: read
jobs:
build:
name: Build distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install build tools
run: pip install build "setuptools>=68.0,<76" twine
- name: Install package (editable) for smoke checks
run: pip install -e .
- name: Build sdist and wheel
run: python -m build
- name: Check dist
continue-on-error: true
run: twine check dist/*
- name: Verify version sync
run: python scripts/check_version_sync.py
- name: Run release smoke test
run: python scripts/release_smoke_test.py
- name: Show built packages
run: ls -la dist/
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: dist
path: dist/
publish:
name: Publish to PyPI
needs: build
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/texthumanize
steps:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: dist
path: dist/
- name: Show packages to publish
run: ls -la dist/
- name: Publish to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
python -m pip install --upgrade pip
python -m pip install "twine>=6.2.0" "pkginfo>=1.12.1.2"
python -m twine upload --skip-existing dist/*