|
|
4e0f6a |
%global __python3 /usr/bin/python3.11
|
|
|
4e0f6a |
%global python3_pkgversion 3.11
|
|
|
4e0f6a |
|
|
|
4e0f6a |
Name: python%{python3_pkgversion}-iniconfig
|
|
|
4e0f6a |
Version: 1.1.1
|
|
|
4e0f6a |
Release: 2%{?dist}
|
|
|
4e0f6a |
Summary: Brain-dead simple parsing of ini files
|
|
|
4e0f6a |
License: MIT
|
|
|
4e0f6a |
URL: http://github.com/RonnyPfannschmidt/iniconfig
|
|
|
4e0f6a |
BuildArch: noarch
|
|
|
4e0f6a |
BuildRequires: python%{python3_pkgversion}-devel
|
|
|
4e0f6a |
BuildRequires: python%{python3_pkgversion}-rpm-macros
|
|
|
4e0f6a |
BuildRequires: python%{python3_pkgversion}-setuptools
|
|
|
4e0f6a |
BuildRequires: python%{python3_pkgversion}-wheel
|
|
|
4e0f6a |
|
|
|
4e0f6a |
Source0: %{pypi_source iniconfig}
|
|
|
4e0f6a |
|
|
|
4e0f6a |
# pytest 6+ needs this and this uses pytest for tests
|
|
|
4e0f6a |
%bcond_without tests
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%if %{with tests}
|
|
|
4e0f6a |
BuildRequires: python%{python3_pkgversion}-pytest
|
|
|
4e0f6a |
%endif
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%global _description %{expand:
|
|
|
4e0f6a |
iniconfig is a small and simple INI-file parser module
|
|
|
4e0f6a |
having a unique set of features:
|
|
|
4e0f6a |
|
|
|
4e0f6a |
* tested against Python2.4 across to Python3.2, Jython, PyPy
|
|
|
4e0f6a |
* maintains order of sections and entries
|
|
|
4e0f6a |
* supports multi-line values with or without line-continuations
|
|
|
4e0f6a |
* supports "#" comments everywhere
|
|
|
4e0f6a |
* raises errors with proper line-numbers
|
|
|
4e0f6a |
* no bells and whistles like automatic substitutions
|
|
|
4e0f6a |
* iniconfig raises an Error if two sections have the same name.}
|
|
|
4e0f6a |
%description %_description
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%prep
|
|
|
4e0f6a |
%autosetup -n iniconfig-%{version}
|
|
|
4e0f6a |
# Remove undeclared dependency on python-py
|
|
|
4e0f6a |
# Merged upstream https://github.com/pytest-dev/iniconfig/pull/47
|
|
|
4e0f6a |
sed -i "s/py\.test/pytest/" testing/test_iniconfig.py
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
# Remove dependency on setuptools-scm
|
|
|
4e0f6a |
sed -i "s/ *use_scm_version=.*,/version='%{version}',/" setup.py
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%build
|
|
|
4e0f6a |
%py3_build
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%install
|
|
|
4e0f6a |
%py3_install
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%if %{with tests}
|
|
|
4e0f6a |
%check
|
|
|
4e0f6a |
%pytest
|
|
|
4e0f6a |
%endif
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%files -n python%{python3_pkgversion}-iniconfig
|
|
|
4e0f6a |
%doc README.txt
|
|
|
4e0f6a |
%license LICENSE
|
|
|
4e0f6a |
%{python3_sitelib}/iniconfig-%{version}-py%{python3_version}.egg-info/
|
|
|
4e0f6a |
%{python3_sitelib}/iniconfig/
|
|
|
4e0f6a |
|
|
|
4e0f6a |
|
|
|
4e0f6a |
%changelog
|
|
|
4e0f6a |
* Wed Feb 01 2023 Charalampos Stratakis <cstratak@redhat.com> - 1.1.1-2
|
|
|
4e0f6a |
- Enable tests
|
|
|
4e0f6a |
|
|
|
4e0f6a |
* Fri Dec 02 2022 Charalampos Stratakis <cstratak@redhat.com> - 1.1.1-1
|
|
|
4e0f6a |
- Initial package
|
|
|
4e0f6a |
- Fedora contributions by:
|
|
|
4e0f6a |
Lumir Balhar <lbalhar@redhat.com>
|
|
|
4e0f6a |
Miro HronĨok <miro@hroncok.cz>
|
|
|
4e0f6a |
Tomas Hrnciar <thrnciar@redhat.com>
|