%{?!python3_pkgversion:%global python3_pkgversion 3} %global srcname lunr %global forgeurl https://github.com/yeraydiazdiaz/lunr.py %global tag 0.6.2 %forgemeta Name: python-%{srcname} Version: 0.6.2 Release: %autorelease Summary: A Python implementation of Lunr.js License: MIT URL: %{forgeurl} Source0: %{forgesource} BuildArch: noarch BuildRequires: make BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python%{python3_pkgversion}-setuptools BuildRequires: python3dist(sphinx-rtd-theme) %{?python_enable_dependency_generator} %description Lunr is a simple full text search solution for situations where deploying a full scale solution like Elasticsearch isn't possible, viable or you're simply prototyping. Lunr parses a set of documents and creates an inverted index for quick full text searches in the same way other more complicated solution. The trade-off is that Lunr keeps the inverted index in memory and requires you to recreate or read the index at the start of your application. %package -n python%{python3_pkgversion}-%{srcname} Summary: %{summary} %{?python_provide:%python_provide python3-%{srcname}} %description -n python%{python3_pkgversion}-%{srcname} %{description} %prep %forgeautosetup -p1 %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel make -C docs %install %pyproject_install %pyproject_save_files %{srcname} %check %pyproject_check_import -t %files -n python%{python3_pkgversion}-%{srcname} %license LICENSE %doc README.md readme.rst CHANGELOG.md %{python3_sitelib}/%{srcname}/ %{python3_sitelib}/%{srcname}-%{version}.dist-info/ %changelog %autochangelog