%bcond_without check %global srcname myrepos-utils Name: python-%{srcname} Version: 0.0.1.1 Release: %autorelease Summary: Additional utilities for myrepos License: MIT URL: https://git.sr.ht/~michel-slm/myrepos-utils Source0: %{pypi_source} BuildArch: noarch BuildRequires: python3-devel %global _description %{expand: Tomli-W is a Python library for writing TOML. It is a write-only counterpart to Tomli, which is a read-only TOML parser. Tomli-W is fully compatible with TOML v1.0.0.} %description %_description %package -n %{srcname} Summary: %{summary} Requires: myrepos %description -n %{srcname} %_description %prep %autosetup -p1 -n %{srcname}-%{version} %generate_buildrequires %pyproject_buildrequires %{?with_check:-r requirements-test.txt} %build %pyproject_wheel %install %pyproject_install %pyproject_save_files myrepos_utils %check %pyproject_check_import myrepos_utils %if %{with check} %pytest %endif %files -n %{srcname} -f %{pyproject_files} %doc README.md %license COPYING.md %{_bindir}/mr-utils %changelog %autochangelog