Sync from SUSE:SLFO:Main python-Pygments revision e29275667afaa60ee7c30582040ae60b
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-Pygments
|
||||
#
|
||||
# Copyright (c) 2023 SUSE LLC
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -25,31 +25,29 @@
|
||||
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-Pygments
|
||||
Version: 2.15.1
|
||||
Version: 2.18.0
|
||||
Release: 0
|
||||
Summary: A syntax highlighting package written in Python
|
||||
License: BSD-2-Clause
|
||||
Group: Development/Languages/Python
|
||||
URL: https://pygments.org
|
||||
Source: https://files.pythonhosted.org/packages/source/P/Pygments/Pygments-%{version}.tar.gz
|
||||
BuildRequires: %{python_module base >= 3.7}
|
||||
Source: https://files.pythonhosted.org/packages/source/P/Pygments/pygments-%{version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAM skip-wcag-contrast-ratio.patch gh#pygments/pygments!2564 mcepl@suse.com
|
||||
# Don't make wcag-contrast-ratio mandatory for testing
|
||||
Patch0: skip-wcag-contrast-ratio.patch
|
||||
BuildRequires: %{python_module base >= 3.8}
|
||||
BuildRequires: %{python_module hatchling}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module pytest >= 7}
|
||||
BuildRequires: %{python_module setuptools >= 61}
|
||||
BuildRequires: %{python_module wcag-contrast-ratio}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros >= 20210929
|
||||
# Preferred for plugin loading, see https://pygments.org/docs/plugins/
|
||||
%if 0%{?python_version_nodots} < 38
|
||||
Requires: python-importlib-metadata
|
||||
%endif
|
||||
%if %{with libalternatives}
|
||||
Requires: alts
|
||||
BuildRequires: alts
|
||||
%else
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun):update-alternatives
|
||||
Requires(postun): update-alternatives
|
||||
%endif
|
||||
Provides: python-pygments = %{version}
|
||||
Obsoletes: python-pygments < %{version}
|
||||
@@ -69,7 +67,9 @@ source code. Highlights are:
|
||||
* highlights Brainfuck
|
||||
|
||||
%prep
|
||||
%autosetup -n Pygments-%{version} -p1
|
||||
%autosetup -n pygments-%{version} -p1
|
||||
# Remove unneeded executable bit
|
||||
chmod -x pygments/formatters/_mapping.py pygments/lexers/gsql.py
|
||||
|
||||
%build
|
||||
%pyproject_wheel
|
||||
@@ -84,7 +84,6 @@ install -Dm0644 doc/pygmentize.1 %{buildroot}%{_mandir}/man1/pygmentize.1
|
||||
}
|
||||
|
||||
%check
|
||||
# skip test that requires wcag-contrast-ratio Python package
|
||||
%pytest
|
||||
|
||||
%pre
|
||||
@@ -103,6 +102,6 @@ install -Dm0644 doc/pygmentize.1 %{buildroot}%{_mandir}/man1/pygmentize.1
|
||||
%python_alternative %{_bindir}/pygmentize
|
||||
%python_alternative %{_mandir}/man1/pygmentize.1%{ext_man}
|
||||
%{python_sitelib}/pygments
|
||||
%{python_sitelib}/Pygments-%{version}*-info
|
||||
%{python_sitelib}/pygments-%{version}*-info
|
||||
|
||||
%changelog
|
||||
|
||||
Reference in New Issue
Block a user