From fe8efa9b63a370b8b386a0364bc1eca0326bdca2113153f7bc6ab7548534cba0 Mon Sep 17 00:00:00 2001 From: Steve Kowalik Date: Wed, 7 May 2025 07:02:02 +0000 Subject: [PATCH] - Switch to pyproject macros. - No more greedy globs in %files. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-black?expand=0&rev=12 --- python-pytest-black.changes | 6 ++++++ python-pytest-black.spec | 14 ++++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/python-pytest-black.changes b/python-pytest-black.changes index 437794c..371acc9 100644 --- a/python-pytest-black.changes +++ b/python-pytest-black.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed May 7 06:47:48 UTC 2025 - Steve Kowalik + +- Switch to pyproject macros. +- No more greedy globs in %files. + ------------------------------------------------------------------- Mon Mar 15 10:47:48 UTC 2021 - Ben Greiner diff --git a/python-pytest-black.spec b/python-pytest-black.spec index 5abcc62..355b66c 100644 --- a/python-pytest-black.spec +++ b/python-pytest-black.spec @@ -1,7 +1,7 @@ # # spec file for package python-pytest-black # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,8 +16,6 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 Name: python-pytest-black Version: 0.3.12 Release: 0 @@ -27,8 +25,10 @@ URL: https://github.com/shopkeep/pytest-black Source: https://files.pythonhosted.org/packages/source/p/pytest-black/pytest-black-%{version}.tar.gz # PATCH-FIX-UPSTREAM fix-pytest-makefile.patch -- gh#shopkeep/pytest-black#53 Patch0: https://github.com/shopkeep/pytest-black/pull/53.patch#/fix-pytest-makefile.patch +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools_scm} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-black @@ -49,10 +49,10 @@ A pytest plugin to enable format checking with black. %autosetup -p1 -n pytest-black-%{version} %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check @@ -61,6 +61,8 @@ A pytest plugin to enable format checking with black. %files %{python_files} %doc README.md %license LICENSE -%{python_sitelib}/* +%{python_sitelib}/pytest_black.py +%pycache_only %{python_sitelib}/__pycache__/pytest_black*.pyc +%{python_sitelib}/pytest_black-%{version}.dist-info %changelog