From 31026a01f57eaf54d88db73e895bcad7dfae7515 Mon Sep 17 00:00:00 2001 From: prostomarkeloff <28061158+prostomarkeloff@users.noreply.github.com> Date: Fri, 4 Sep 2026 23:04:16 +0300 Subject: [PATCH] =?UTF-8?q?README,=20CI:=20the=20Python=20package=20is=20o?= =?UTF-8?q?n=20PyPI=20=E2=80=94=20pip=20install=20difflib-fast?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/CI.yml | 7 +++---- README.md | 21 +++++++++------------ 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 25002f5..e72caaa 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -1,8 +1,7 @@ # Build + test, then on a version tag (`vX.Y.Z`) attach wheels + sdist to a GitHub Release. -# crates.io is published manually (`cargo publish`). No PyPI — install the Python package from a -# release wheel or via `pip install git+https://github.com/prostomarkeloff/difflib-fast`. -# -# No secrets needed — the GitHub Release uses the built-in GITHUB_TOKEN. +# crates.io is published manually (`cargo publish`), and so is PyPI: download the release's +# wheels + sdist and `uv publish` them. Nothing here needs a secret — the GitHub Release uses the +# built-in GITHUB_TOKEN. # # abi3 (pyo3 abi3-py39) → one wheel per platform/arch works on CPython 3.9+, so no per-Python matrix. name: CI diff --git a/README.md b/README.md index 8f2a8e6..f9bee51 100644 --- a/README.md +++ b/README.md @@ -253,27 +253,24 @@ Swap `difflib.SequenceMatcher(...).ratio()` for `difflib_fast.ratio(...)` and th back — hundreds of times faster per call, and **thousands of times** faster when you score a whole corpus. That's the entire change: `import difflib_fast`. -**No PyPI** — `pip install difflib-fast` won't work. Two ways to install: - -**1. Prebuilt wheel — no Rust toolchain needed.** The wheels are `cp39-abi3`, so one wheel per platform -works on **every CPython ≥ 3.9, including 3.14**. GitHub Releases isn't a package index, so pip can't -pick the wheel for you — grab the one for your platform from the -[Releases page](https://github.com/prostomarkeloff/difflib-fast/releases/latest) and install it by URL: - ```bash -# macOS Apple Silicon — swap the filename for your platform (see below): -pip install https://github.com/prostomarkeloff/difflib-fast/releases/download/v0.3.5/difflib_fast-0.3.5-cp39-abi3-macosx_11_0_arm64.whl +pip install difflib-fast ``` -| platform | wheel suffix | +The wheels on [PyPI](https://pypi.org/project/difflib-fast/) are `cp39-abi3`, so one wheel per +platform works on **every CPython ≥ 3.9, including 3.14** — no Rust toolchain needed: + +| platform | wheel | |---|---| -| macOS Apple Silicon | `…-macosx_11_0_arm64.whl` | +| macOS Apple Silicon | `…-macosx_11_0_arm64.whl` (ships the Metal GPU path) | | macOS Intel | `…-macosx_10_12_x86_64.whl` | | Linux x86_64 | `…-manylinux_2_17_x86_64.manylinux2014_x86_64.whl` | | Linux aarch64 | `…-manylinux_2_17_aarch64.manylinux2014_aarch64.whl` | | Windows x64 | `…-win_amd64.whl` | -**2. From source — needs a Rust toolchain** (pip drives maturin automatically, no manual build): +The same wheels are attached to every +[GitHub release](https://github.com/prostomarkeloff/difflib-fast/releases/latest). Any other +platform builds from source — pip drives maturin, so it only needs a Rust toolchain: ```bash pip install git+https://github.com/prostomarkeloff/difflib-fast