%global pkg_name jaraco-path %global pypi_name jaraco.path Name: python-%{pkg_name} Version: 3.3.1 Release: 1%{?dist} Summary: Miscellaneous path functions License: MIT URL: https://github.com/jaraco/jaraco.path Source0: https://github.com/jaraco/jaraco.path/archive/v%{version}.tar.gz Patch1: 1.patch BuildArch: noarch BuildRequires: python3-devel BuildRequires: pyproject-rpm-macros BuildRequires: pytest %global _description %{expand: jaraco.path provides cross platform hidden file detection} %description %_description %package -n python3-%{pkg_name} Summary: %{summary} %description -n python3-%{pkg_name} %_description %prep %autosetup -p1 -n %{pypi_name}-%{version} %generate_buildrequires export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %pyproject_buildrequires -r %build export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %pyproject_wheel %install %pyproject_install %pyproject_save_files jaraco %check # When pytest collects tests, it ignores hidden directories by default, because the `.*` pattern is ignored. # However, if upstream sets https://docs.pytest.org/en/stable/reference.html#confval-norecursedirs it replaces the default. If upstream does not explicitly list `.*`, hidden directories are not ignored. # See https://bugzilla.redhat.com/show_bug.cgi?id=1935212 for more info. %pytest --ignore %_pyproject_builddir %files -n python3-%{pkg_name} -f %{pyproject_files} %license LICENSE %doc README.rst %exclude %{python3_sitelib}/jaraco/__init__* %exclude %{python3_sitelib}/jaraco/__pycache__/__init__* %exclude %{python3_sitelib}/jaraco %changelog * Tue Mar 02 2021 Tomas Hrnciar - 3.3.1-1 - Initial package