## START: Set by rpmautospec ## (rpmautospec version 0.3.0) %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 6; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec Name: python-autoprop Version: 4.1.0 Release: %autorelease Summary: Infer properties from accessor methods # SPDX License: MIT URL: https://github.com/kalekundert/autoprop Source: %{pypi_source autoprop} BuildArch: noarch BuildRequires: python3-devel %global common_description %{expand: This package provides a library for automatically filling in classes with properties (e.g. obj.x) corresponding to each accessor method (e.g. obj.get_x(), obj.set_x()). The biggest reasons to use autoprop are: • Less boilerplate than defining properties manually. • Sophisticated support for cached properties.} %description %{common_description} %package -n python3-autoprop Summary: %{summary} %description -n python3-autoprop %{common_description} %prep %autosetup -n autoprop-%{version} # Patch out coverage dependencies sed -r -i '/\b(pytest-cov|coveralls)\b/d' pyproject.toml # Remove useless shebang lines. # # Originally sent upstream, # https://github.com/kalekundert/autoprop/pull/8, but this author wants to keep # them; see: # https://github.com/kalekundert/autoprop/pull/8#issuecomment-1008057715 # # Script version instead of patch for forward-compatibility. # # The find-then-modify pattern keeps us from discarding mtimes on any sources # that do not need modification. find . -type f -name '*.py' -exec \ gawk '/^#!/ { print FILENAME }; { nextfile }' '{}' '+' | xargs -r -t sed -r -i '1{/^#!/d}' %generate_buildrequires %pyproject_buildrequires -x test %build %pyproject_wheel %install %pyproject_install %pyproject_save_files autoprop %check %pytest tests %files -n python3-autoprop -f %{pyproject_files} %license LICENSE.txt %doc CHANGELOG.md %doc README.rst %changelog * Fri May 26 2023 Benjamin A. Beasley 4.1.0-6 - Do not number the sole Source * Fri Jan 20 2023 Fedora Release Engineering 4.1.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Fri Oct 21 2022 Benjamin A. Beasley 4.1.0-4 - Confirm License is SPDX MIT * Fri Jul 22 2022 Fedora Release Engineering 4.1.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Mon Jun 13 2022 Python Maint 4.1.0-2 - Rebuilt for Python 3.11 * Tue May 31 2022 Benjamin A. Beasley 4.1.0-1 - Update to 4.1.0 (close RHBZ#2091739) * Fri Mar 11 2022 Benjamin A. Beasley 4.0.2-2 - Convert shebang removal from patch to script * Wed Mar 02 2022 Benjamin A. Beasley 4.0.2-1 - Initial package (close RHBZ#2038330)