mirror of
https://abf.rosa.ru/djam/python-pygments.git
synced 2025-02-23 06:52:50 +00:00
124 lines
3.3 KiB
RPMSpec
124 lines
3.3 KiB
RPMSpec
%define tarname pygments
|
|
|
|
Summary: Syntax highlighting package written in Python
|
|
Name: python-pygments
|
|
Version: 2.11.2
|
|
Release: 1
|
|
License: BSD
|
|
Group: Development/Python
|
|
URL: https://pygments.org
|
|
Source0: https://github.com/pygments/pygments/archive/%{version}.tar.gz?/%{tarname}-%{version}.tar.gz
|
|
BuildRequires: pkgconfig(python)
|
|
BuildRequires: pkgconfig(python3)
|
|
BuildRequires: pythonegg(setuptools)
|
|
BuildRequires: python3egg(setuptools)
|
|
BuildRequires: python38-devel
|
|
BuildRequires: python38-setuptools
|
|
Requires: python-pkg-resources
|
|
BuildArch: noarch
|
|
|
|
%description
|
|
Pygments is a syntax highlighting package written in Python. It is a
|
|
generic syntax highlighter for general use in all kinds of software
|
|
such as forum systems, wikis or other applications that need to
|
|
prettify source code. Highlights are:
|
|
|
|
* a wide range of common languages and markup formats is supported
|
|
* special attention is paid to details, increasing quality by a fair amount
|
|
* support for new languages and formats are added easily
|
|
* a number of output formats, presently HTML, LaTeX, RTF, SVG and ANSI
|
|
sequences
|
|
* it is usable as a command-line tool and as a library
|
|
* ... and it highlights even Brainf*ck!
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
%package -n python-pygments
|
|
Summary: Syntax highlighting package written in Python3
|
|
Group: Development/Python
|
|
|
|
%description -n python-pygments
|
|
Pygments is a syntax highlighting package written in Python. It is a
|
|
generic syntax highlighter for general use in all kinds of software
|
|
such as forum systems, wikis or other applications that need to
|
|
prettify source code.
|
|
|
|
%files -n python-pygments
|
|
%doc AUTHORS CHANGES LICENSE
|
|
%{_bindir}/pygmentize2
|
|
%{python_sitelib}/*
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
%package -n python3-pygments
|
|
Summary: Syntax highlighting package written in Python3
|
|
Group: Development/Python
|
|
|
|
%description -n python3-pygments
|
|
Pygments is a syntax highlighting package written in Python. It is a
|
|
generic syntax highlighter for general use in all kinds of software
|
|
such as forum systems, wikis or other applications that need to
|
|
prettify source code.
|
|
|
|
%files -n python3-pygments
|
|
%doc AUTHORS CHANGES LICENSE
|
|
%{python3_sitelib}/*
|
|
%{_bindir}/pygmentize3
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
%package -n python38-pygments
|
|
Summary: Syntax highlighting package written in Python3
|
|
Group: Development/Python
|
|
|
|
%description -n python38-pygments
|
|
Pygments is a syntax highlighting package written in Python. It is a
|
|
generic syntax highlighter for general use in all kinds of software
|
|
such as forum systems, wikis or other applications that need to
|
|
prettify source code.
|
|
|
|
%files -n python38-pygments
|
|
%doc AUTHORS CHANGES LICENSE
|
|
%{python38_sitelib}/*
|
|
%{_bindir}/pygmentize
|
|
%{_mandir}/man1/pygmentize.*
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
%prep
|
|
%setup -qn %{tarname}-%{version}
|
|
|
|
cp -a . %{py3dir}
|
|
cp -a . %{py38dir}
|
|
|
|
%build
|
|
pushd %{py3dir}
|
|
%py3_build
|
|
popd
|
|
|
|
pushd %{py38dir}
|
|
%py38_build
|
|
popd
|
|
|
|
%py_build
|
|
|
|
%install
|
|
%py_install
|
|
pushd %{buildroot}%{_bindir}
|
|
mv pygmentize pygmentize2
|
|
popd
|
|
|
|
pushd %{py3dir}
|
|
%py3_install
|
|
popd
|
|
|
|
pushd %{buildroot}%{_bindir}
|
|
mv pygmentize pygmentize3
|
|
popd
|
|
|
|
|
|
pushd %{py38dir}
|
|
%py38_install
|
|
popd
|
|
|
|
install -Dm0644 doc/pygmentize.1 %{buildroot}%{_mandir}/man1/pygmentize.1
|