- Refactor pygments-2.14.patch to not use distutils.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-docutils?expand=0&rev=81
This commit is contained in:
parent
99e4b3adf3
commit
76b2628c85
@ -656,11 +656,11 @@ Index: docutils-0.19/docutils/utils/code_analyzer.py
|
|||||||
from docutils import ApplicationError
|
from docutils import ApplicationError
|
||||||
try:
|
try:
|
||||||
import pygments
|
import pygments
|
||||||
+ from distutils.version import LooseVersion
|
+ from packaging.version import Version
|
||||||
from pygments.lexers import get_lexer_by_name
|
from pygments.lexers import get_lexer_by_name
|
||||||
from pygments.formatters.html import _get_ttype_class
|
from pygments.formatters.html import _get_ttype_class
|
||||||
with_pygments = True
|
with_pygments = True
|
||||||
+ pygments_version = LooseVersion(pygments.__version__)
|
+ pygments_version = Version(pygments.__version__)
|
||||||
except ImportError:
|
except ImportError:
|
||||||
with_pygments = False
|
with_pygments = False
|
||||||
+ pygments_version = '0'
|
+ pygments_version = '0'
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jan 24 06:53:16 UTC 2023 - Steve Kowalik <steven.kowalik@suse.com>
|
||||||
|
|
||||||
|
- Refactor pygments-2.14.patch to not use distutils.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Jan 10 15:42:55 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
|
Tue Jan 10 15:42:55 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
|
||||||
|
|
||||||
|
@ -45,11 +45,13 @@ Requires(post): update-alternatives
|
|||||||
Requires(postun):update-alternatives
|
Requires(postun):update-alternatives
|
||||||
Recommends: python-Pillow
|
Recommends: python-Pillow
|
||||||
Recommends: python-Pygments
|
Recommends: python-Pygments
|
||||||
|
Requires: python-packaging
|
||||||
Recommends: python-roman
|
Recommends: python-roman
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
%if %{with test}
|
%if %{with test}
|
||||||
BuildRequires: %{python_module Pillow}
|
BuildRequires: %{python_module Pillow}
|
||||||
BuildRequires: %{python_module Pygments}
|
BuildRequires: %{python_module Pygments}
|
||||||
|
BuildRequires: %{python_module packaging}
|
||||||
BuildRequires: %{python_module roman}
|
BuildRequires: %{python_module roman}
|
||||||
%endif
|
%endif
|
||||||
%if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3"
|
%if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user