diff --git a/.gitignore b/.gitignore index e4f85a7..9bfd536 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,2 @@ -/tinycss2-0.6.1.tar.gz -/tinycss2-1.0.1.tar.gz -/tinycss2-1.0.2.tar.gz +/tinycss2-*.tar.gz +/css-parsing-tests-*.tar.gz diff --git a/export-git-snapshot.sh b/export-git-snapshot.sh new file mode 100755 index 0000000..73b45f9 --- /dev/null +++ b/export-git-snapshot.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +PROJECT=css-parsing-tests +REPO=git@github.com:SimonSapin/css-parsing-tests.git + +githash=$1 +if [ -z "$githash" ]; then + echo "usage: $0 GITHASH" + exit 1 +fi + +shorthash=${githash:0:8} +outputfile="${PROJECT}"-$shorthash.tar.gz + +rm -rf "${PROJECT}"-temp +git clone "${REPO}" "${PROJECT}"-temp +cd "${PROJECT}"-temp + git archive --prefix="${PROJECT}"-$shorthash/ --format=tar ${githash} \ + | gzip --stdout > ../$outputfile +cd .. +rm -rf "${PROJECT}"-temp +echo "exported source code in $outputfile" diff --git a/python-tinycss2-disable-flake8-isort-for-pytest.patch b/python-tinycss2-disable-flake8-isort-for-pytest.patch deleted file mode 100644 index 6c48258..0000000 --- a/python-tinycss2-disable-flake8-isort-for-pytest.patch +++ /dev/null @@ -1,30 +0,0 @@ -diff --git a/setup.cfg b/setup.cfg -index b3b3c2d..944ca52 100644 ---- a/setup.cfg -+++ b/setup.cfg -@@ -40,8 +40,6 @@ install_requires = - tests_require = - pytest-runner - pytest-cov -- pytest-flake8 -- pytest-isort - python_requires = >= 3.5 - - [options.package_data] -@@ -56,8 +54,6 @@ doc = - test = - pytest-runner - pytest-cov -- pytest-flake8 -- pytest-isort - - [bdist_wheel] - python-tag = py3 -@@ -70,7 +66,6 @@ build-dir = docs/_build - test = pytest - - [tool:pytest] --addopts = --flake8 --isort - norecursedirs = build dist .cache .eggs .git - - [coverage:run] diff --git a/python-tinycss2.spec b/python-tinycss2.spec index 5acd30f..86e7708 100644 --- a/python-tinycss2.spec +++ b/python-tinycss2.spec @@ -1,29 +1,22 @@ %global srcname tinycss2 - -%global py3_prefix python%{python3_pkgversion} - - Name: python-%{srcname} -Version: 1.0.2 +Version: 1.5.1 Release: 1%{?dist} Summary: Low-level CSS parser for Python -License: BSD -URL: https://pypi.python.org/pypi/%{srcname}/ -Source0: https://files.pythonhosted.org/packages/source/t/%{srcname}/%{srcname}-%{version}.tar.gz -# Fedora does not ship pytest's flake8/isort modules -Patch0: %{name}-disable-flake8-isort-for-pytest.patch +License: BSD-3-Clause +URL: https://www.courtbouillon.org/tinycss2/ +Source0: %{pypi_source tinycss2} BuildArch: noarch -# required to run the tests -BuildRequires: %{py3_prefix}-devel -BuildRequires: %{py3_prefix}-pytest -BuildRequires: %{py3_prefix}-pytest-cov -BuildRequires: %{py3_prefix}-pytest-runner -BuildRequires: %{py3_prefix}-pytest-flake8 -BuildRequires: %{py3_prefix}-webencodings >= 0.4 +BuildRequires: python3-devel +BuildRequires: pyproject-rpm-macros + +# The test extra contains linters, we cherry-pick only what we need: +BuildRequires: python3-pytest + %description tinycss2 is a modern, low-level CSS parser for Python. tinycss2 is a rewrite of @@ -31,12 +24,11 @@ tinycss with a simpler API, based on the more recent CSS Syntax Level 3 specification. -%package -n %{py3_prefix}-%{srcname} +%package -n python3-%{srcname} Summary: Low-level CSS parser for Python 3 -Requires: %{py3_prefix}-webencodings >= 0.4 -%{?python_provide:%python_provide %{py3_prefix}-%{srcname}} +%{?python_provide:%python_provide python3-%{srcname}} -%description -n %{py3_prefix}-%{srcname} +%description -n python3-%{srcname} tinycss2 is a modern, low-level CSS parser for Python. tinycss2 is a rewrite of tinycss with a simpler API, based on the more recent CSS Syntax Level 3 specification. @@ -46,30 +38,140 @@ specification. %autosetup -n %{srcname}-%{version} +%generate_buildrequires +%pyproject_buildrequires -r + + %build -%py3_build +%pyproject_wheel %install -%py3_install +%pyproject_install %check -%{__python3} -m pytest -v +%{pytest} # remove files which are only required for unit tests (including test.pyc/.pyo) rm -rf %{buildroot}%{python3_sitelib}/%{srcname}/css-parsing-tests rm -rf %{buildroot}%{python3_sitelib}/%{srcname}/test.py rm -rf %{buildroot}%{python3_sitelib}/%{srcname}/__pycache__/test.*.py? -%files -n %{py3_prefix}-%{srcname} +%files -n python3-%{srcname} %license LICENSE %doc README.rst %{python3_sitelib}/%{srcname}/ -%{python3_sitelib}/%{srcname}-%{version}-py?.?.egg-info/ +%{python3_sitelib}/%{srcname}-%{version}.dist-info/ %changelog +* Sun Nov 23 2025 Felix Schwarz - 1.5.1-1 +- update to 1.5.1 + +* Wed Nov 19 2025 Felix Schwarz - 1.5.0-1 +- update to 1.5.0 + +* Fri Sep 19 2025 Python Maint - 1.4.0-6 +- Rebuilt for Python 3.14.0rc3 bytecode + +* Fri Aug 15 2025 Python Maint - 1.4.0-5 +- Rebuilt for Python 3.14.0rc2 bytecode + +* Fri Jul 25 2025 Fedora Release Engineering - 1.4.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + +* Tue Jun 03 2025 Python Maint - 1.4.0-3 +- Rebuilt for Python 3.14 + +* Sat Jan 18 2025 Fedora Release Engineering - 1.4.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + +* Sat Oct 26 2024 Felix Schwarz - 1.4.0-1 +- update to 1.4.0 + +* Sat Oct 26 2024 Felix Schwarz - 1.3.0-5 +- SPDX conversion + +* Wed Sep 04 2024 Miroslav Suchý - 1.3.0-4 +- convert license to SPDX + +* Fri Jul 19 2024 Fedora Release Engineering - 1.3.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + +* Fri Jun 07 2024 Python Maint - 1.3.0-2 +- Rebuilt for Python 3.13 + +* Tue Apr 23 2024 Felix Schwarz - 1.3.0-1 +- update to 1.3.0 + +* Fri Jan 26 2024 Fedora Release Engineering - 1.2.1-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Mon Jan 22 2024 Fedora Release Engineering - 1.2.1-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Fri Jul 21 2023 Fedora Release Engineering - 1.2.1-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + +* Sat Jul 01 2023 Python Maint - 1.2.1-4 +- Rebuilt for Python 3.12 + +* Mon May 15 2023 Miro Hrončok - 1.2.1-3 +- Drop redundant build dependency on flit, this package uses flit-core + +* Fri Jan 20 2023 Fedora Release Engineering - 1.2.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Tue Oct 18 2022 Felix Schwarz - 1.2.1-1 +- update to 1.2.1 + +* Fri Jul 22 2022 Fedora Release Engineering - 1.1.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Mon Jun 13 2022 Python Maint - 1.1.1-3 +- Rebuilt for Python 3.11 + +* Fri Jan 21 2022 Fedora Release Engineering - 1.1.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Mon Nov 22 2021 Felix Schwarz - 1.1.1-1 +- update to 1.1.1 + +* Tue Jul 27 2021 Fedora Release Engineering - 1.1.0-4 +- Second attempt - Rebuilt for + https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Fri Jun 04 2021 Python Maint - 1.1.0-3 +- Rebuilt for Python 3.10 + +* Wed Jan 27 2021 Fedora Release Engineering - 1.1.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Sat Nov 07 2020 Felix Schwarz - 1.1.0-1 +- update to 1.1.0 + +* Wed Jul 29 2020 Fedora Release Engineering - 1.0.2-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Thu Jun 25 2020 Felix Schwarz - 1.0.2-7 +- add python3-setuptools to BuildRequires + +* Tue May 26 2020 Miro Hrončok - 1.0.2-6 +- Rebuilt for Python 3.9 + +* Thu Jan 30 2020 Fedora Release Engineering - 1.0.2-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Thu Oct 03 2019 Miro Hrončok - 1.0.2-4 +- Rebuilt for Python 3.8.0rc1 (#1748018) + +* Mon Aug 19 2019 Miro Hrončok - 1.0.2-3 +- Rebuilt for Python 3.8 + +* Fri Jul 26 2019 Fedora Release Engineering - 1.0.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + * Mon Apr 29 2019 Felix Schwarz 1.0.2-1 - update to new upstream version 1.0.2 diff --git a/sources b/sources index 223f815..236d2ad 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (tinycss2-1.0.2.tar.gz) = 69bdf52898f9e704c01fe5fd11170e0efc9a6aca14646f5331fc06ebbdf941f9b6c798ded7d93636c7b810b35c659750c3ece3917c5c9cef4092e3e17b382dd1 +SHA512 (tinycss2-1.5.1.tar.gz) = 1c2e1818c27c90f78b1e0af9b4c3c2a0944999691dcea678d0f5ed8a141d6ebd272b8b6763c1eac9d824db0d539e1e238f1e5e6abd2c02d97bb86002da637a10