From 414e445dcfe7921a88ea4f00e651f1c8653aa92a Mon Sep 17 00:00:00 2001 From: Millaguie Date: Fri, 26 Jun 2026 16:48:47 +0200 Subject: [PATCH] feat: publish to PyPI via Trusted Publishing - add release-triggered publish.yml (OIDC, no token) - flesh out packaging metadata: readme, authors, classifiers, urls - bump setuptools floor to 77 for PEP 639 SPDX license support --- .github/workflows/publish.yml | 24 ++++++++++++++++++++++++ pyproject.toml | 22 +++++++++++++++++++++- 2 files changed, 45 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/publish.yml diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..a0c67aa --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,24 @@ +name: Publish to PyPI + +on: + release: + types: [published] + workflow_dispatch: + +jobs: + publish: + runs-on: ubuntu-latest + environment: pypi + permissions: + id-token: write # OIDC — Trusted Publishing, no API token needed + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: "3.12" + - name: Build sdist and wheel + run: | + python -m pip install --upgrade build + python -m build + - name: Publish to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 diff --git a/pyproject.toml b/pyproject.toml index 5ef0de8..de65e65 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,13 +1,33 @@ [build-system] -requires = ["setuptools>=68.0"] +requires = ["setuptools>=77.0"] build-backend = "setuptools.build_meta" [project] name = "ownsearch" version = "0.1.0" description = "Smart full-text and semantic search for your local documents" +readme = "README.md" requires-python = ">=3.10" license = "GPL-3.0-only" +license-files = ["LICENSE"] +authors = [ + { name = "Millaguie" }, +] +keywords = ["search", "full-text-search", "semantic-search", "embeddings", "sqlite", "fts5", "ollama", "cli"] +classifiers = [ + "Environment :: Console", + "Intended Audience :: End Users/Desktop", + "Operating System :: OS Independent", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3 :: Only", + "Topic :: Utilities", + "Topic :: Text Processing :: Indexing", +] + +[project.urls] +Homepage = "https://github.com/millaguie/ownsearch" +Repository = "https://github.com/millaguie/ownsearch" +Issues = "https://github.com/millaguie/ownsearch/issues" [project.scripts] ownsearch = "ownsearch:main"