From 14f9748957577b2945272f2351c5fdfd743f022f Mon Sep 17 00:00:00 2001 From: WorldTeacher Date: Fri, 21 Nov 2025 09:46:38 +0100 Subject: [PATCH] feat: rework pyproject to allow installing only parts --- pyproject.toml | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 9c161cb..31d627e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -8,13 +8,26 @@ authors = [ ] requires-python = ">=3.13" dependencies = [ - "beautifulsoup4>=4.14.2", - "cloudscraper>=1.2.71", - "playwright>=1.55.0", "regex>=2025.9.18", +] + +[project.optional-dependencies] +# SRU API feature: for accessing library catalogs via SRU protocol +sru = [ "requests>=2.32.5", ] +# Catalogue feature: web scraping local library catalog +catalogue = [ + "requests>=2.32.5", + "beautifulsoup4>=4.12.0", +] + +# Install all features +all = [ + "bibapi[sru,catalogue]", +] + [build-system] requires = ["uv_build >= 0.9.5, <0.10.0"] build-backend = "uv_build"