commit 182c9b45d4da325cfd244ef9264d5ba8a2c01a96 Author: tigro Date: Sun Jan 5 12:10:05 2025 +0300 import python-expandvars-0.12.0-7.el10 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a94b5d5 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/expandvars-0.12.0.tar.gz diff --git a/.python-expandvars.metadata b/.python-expandvars.metadata new file mode 100644 index 0000000..b517f89 --- /dev/null +++ b/.python-expandvars.metadata @@ -0,0 +1 @@ +370148b7a0d4183c852772b1f4e1e21db6c6696e SOURCES/expandvars-0.12.0.tar.gz diff --git a/SPECS/python-expandvars.spec b/SPECS/python-expandvars.spec new file mode 100644 index 0000000..95fa938 --- /dev/null +++ b/SPECS/python-expandvars.spec @@ -0,0 +1,97 @@ +## START: Set by rpmautospec +## (rpmautospec version 0.6.5) +## RPMAUTOSPEC: autorelease, autochangelog +%define autorelease(e:s:pb:n) %{?-p:0.}%{lua: + release_number = 7; + 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-expandvars +Version: 0.12.0 +Release: %autorelease +Summary: Expand system variables Unix style + +# SPDX +License: MIT +URL: https://github.com/sayanarijit/expandvars +Source: %{pypi_source expandvars} + +BuildArch: noarch + +BuildRequires: python3-devel + +# Most of the dependencies in the “test” extra and almost everything tox.ini +# pertain to linting and coverage analysis. Rather than working around all of +# these, it is simpler to BR and invoke pytest manually. +# https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_linters +BuildRequires: %{py3_dist pytest} + +%global common_description %{expand: +This module is inspired by GNU bash’s variable expansion features. It can be +used as an alternative to Python’s os.path.expandvars function. + +A good use case is reading config files with the flexibility of reading values +from environment variables using advanced features like returning a default +value if some variable is not defined.} + +%description %{common_description} + + +%package -n python3-expandvars +Summary: %{summary} + +%description -n python3-expandvars %{common_description} + + +%prep +%autosetup -n expandvars-%{version} +# https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_linters +sed -r -i "s/--cov[^[:blank:]'\"]*[[:blank:]]*//g" pyproject.toml + + +%generate_buildrequires +%pyproject_buildrequires + + +%build +%pyproject_wheel + + +%install +%pyproject_install +%pyproject_save_files -l expandvars + + +%check +%pytest + + +%files -n python3-expandvars -f %{pyproject_files} +%doc README.md + + +%changelog +* Sun Jan 05 2025 Arkady L. Shane - 0.12.0-7 +- Rebuilt for MSVSphere 10 + +## START: Generated by rpmautospec +* Fri Jul 19 2024 Fedora Release Engineering - 0.12.0-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + +* Fri Jun 07 2024 Python Maint - 0.12.0-6 +- Rebuilt for Python 3.13 + +* Fri Jan 26 2024 Fedora Release Engineering - 0.12.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Mon Jan 22 2024 Fedora Release Engineering - 0.12.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Mon Dec 18 2023 Benjamin A. Beasley - 0.12.0-2 +- Assert that %%pyproject_files contains a license file + +* Mon Dec 18 2023 Benjamin A. Beasley - 0.12.0-1 +- Initial package (close RHBZ#2254717) +## END: Generated by rpmautospec