|
|
|
@ -0,0 +1,122 @@
|
|
|
|
|
## START: Set by rpmautospec
|
|
|
|
|
## (rpmautospec version 0.3.5)
|
|
|
|
|
## RPMAUTOSPEC: autorelease, autochangelog
|
|
|
|
|
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
|
|
|
|
|
release_number = 1;
|
|
|
|
|
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
|
|
|
|
|
|
|
|
|
|
# Let’s try to build this as early as we can, since it’s a dependency for
|
|
|
|
|
# some important libraries, such as python-platformdirs.
|
|
|
|
|
%bcond_with bootstrap
|
|
|
|
|
%if %{without bootstrap}
|
|
|
|
|
%bcond_without tests
|
|
|
|
|
%else
|
|
|
|
|
%bcond_with tests
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
Name: python-hatch-vcs
|
|
|
|
|
Version: 0.3.0
|
|
|
|
|
Release: %autorelease
|
|
|
|
|
Summary: Hatch plugin for versioning with your preferred VCS
|
|
|
|
|
|
|
|
|
|
# SPDX
|
|
|
|
|
License: MIT
|
|
|
|
|
URL: https://github.com/ofek/hatch-vcs
|
|
|
|
|
Source0: %{pypi_source hatch_vcs}
|
|
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
|
|
|
|
|
|
%if %{with tests}
|
|
|
|
|
BuildRequires: python3dist(pytest)
|
|
|
|
|
BuildRequires: git-core
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%global common_description %{expand:
|
|
|
|
|
This provides a plugin for Hatch that uses your preferred version control
|
|
|
|
|
system (like Git) to determine project versions.}
|
|
|
|
|
|
|
|
|
|
%description %{common_description}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package -n python3-hatch-vcs
|
|
|
|
|
Summary: %{summary}
|
|
|
|
|
|
|
|
|
|
%description -n python3-hatch-vcs %{common_description}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%autosetup -n hatch_vcs-%{version}
|
|
|
|
|
# EPEL9-specific: allow python-setuptools_scm 6.0.1
|
|
|
|
|
sed -r -i 's/(setuptools-scm>=6\.)4\.0/\10\.1/' pyproject.toml
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%generate_buildrequires
|
|
|
|
|
%pyproject_buildrequires
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%pyproject_wheel
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%pyproject_install
|
|
|
|
|
%pyproject_save_files hatch_vcs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
%if %{with tests}
|
|
|
|
|
# EPEL9: This test fails with setuptools-scm < 6.4.0. Upstream assumes that
|
|
|
|
|
# happens only for Python 2 (and skips the test accordingly), but we have
|
|
|
|
|
# allowed setuptools-scm 6.0.1 on Python 3 as well.
|
|
|
|
|
k="${k-}${k+ and }not test_fallback"
|
|
|
|
|
%pytest -k "${k-}"
|
|
|
|
|
%else
|
|
|
|
|
%pyproject_check_import
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -n python3-hatch-vcs -f %{pyproject_files}
|
|
|
|
|
%doc HISTORY.md
|
|
|
|
|
%doc README.md
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Thu Aug 24 2023 Sergey Cherevko <s.cherevko@msvsphere.ru> - 0.3.0-1
|
|
|
|
|
- Rebuilt for MSVSphere 9.2
|
|
|
|
|
|
|
|
|
|
* Tue Jul 25 2023 Benjamin A. Beasley <code@musicinmybrain.net> - 0.3.0-1
|
|
|
|
|
- Update to 0.3.0 (close RHBZ#2152320)
|
|
|
|
|
- We can now rely on pyproject-rpm-macros >= 1.2.0
|
|
|
|
|
- The LICENSE.txt file is now handled in pyproject_files
|
|
|
|
|
- The setuptools_scm 7 patch is now merged upstream
|
|
|
|
|
|
|
|
|
|
* Tue Jul 25 2023 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.1-2
|
|
|
|
|
- Use hatchling’s new “prepare_metadata_…” hook support for BR’s
|
|
|
|
|
|
|
|
|
|
* Tue Feb 14 2023 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.1-1
|
|
|
|
|
- Update to 0.2.1
|
|
|
|
|
|
|
|
|
|
* Tue Feb 14 2023 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-6
|
|
|
|
|
- EPEL9: allow python-setuptools_scm 6.0.1
|
|
|
|
|
- Skip test_fallback, as upstream does for Python 2.7, due to the
|
|
|
|
|
downgraded setuptools-scm version.
|
|
|
|
|
|
|
|
|
|
* Tue Feb 14 2023 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-5
|
|
|
|
|
- Confirm License is SPDX MIT
|
|
|
|
|
|
|
|
|
|
* Sun Sep 11 2022 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-4
|
|
|
|
|
- Fix extra newline in description
|
|
|
|
|
|
|
|
|
|
* Fri May 06 2022 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-3
|
|
|
|
|
- Use wheel-building support to generate BR’s
|
|
|
|
|
|
|
|
|
|
* Sun May 01 2022 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-2
|
|
|
|
|
- Adjust for pyproject-rpm-macros >= 1.1.0
|
|
|
|
|
|
|
|
|
|
* Fri Apr 22 2022 Benjamin A. Beasley <code@musicinmybrain.net> - 0.2.0-1
|
|
|
|
|
- Initial package (close RHBZ#2077832)
|