!2 Drop python2 support

From: @si-gui
Reviewed-by: @ultra_planet
Signed-off-by: @ultra_planet
This commit is contained in:
openeuler-ci-bot 2020-11-11 17:47:45 +08:00 committed by Gitee
commit 8190837f69
2 changed files with 8 additions and 18 deletions

View File

@ -1,6 +1,6 @@
Name: python-m2r Name: python-m2r
Version: 0.1.15 Version: 0.1.15
Release: 3 Release: 4
Summary: A converter for markdown to reStructuredText Summary: A converter for markdown to reStructuredText
License: MIT License: MIT
URL: https://github.com/miyakogi/m2r URL: https://github.com/miyakogi/m2r
@ -10,15 +10,6 @@ BuildArch: noarch
%description %description
The package converts a markdown file including reStructuredText (rst) markups to a valid rST format. The package converts a markdown file including reStructuredText (rst) markups to a valid rST format.
%package -n python2-m2r
BuildRequires: python2-devel python2-docutils python2-mistune python2-pygments python2-mock
Requires: python2-docutils python2-mistune
Summary: A converter for markdown to reStructuredText
%{?python_provide:%python_provide python2-m2r}
%description -n python2-m2r
The package converts a markdown file including reStructuredText (rst) markups to a valid rST format.
%package -n python3-m2r %package -n python3-m2r
BuildRequires: python3-devel python3-docutils python3-mistune python3-pygments python3-mock BuildRequires: python3-devel python3-docutils python3-mistune python3-pygments python3-mock
Requires: python3-docutils python3-mistune Requires: python3-docutils python3-mistune
@ -34,22 +25,14 @@ rm -rf m2r.egg-info
sed -i '1{\@^#!/usr/bin/env python@d}' m2r.py sed -i '1{\@^#!/usr/bin/env python@d}' m2r.py
%build %build
%py2_build
%py3_build %py3_build
%install %install
%py2_install
%py3_install %py3_install
%check %check
PYTHONPATH=$(pwd) %{__python2} setup.py test -s tests
PYTHONPATH=$(pwd) %{__python3} setup.py test -s tests PYTHONPATH=$(pwd) %{__python3} setup.py test -s tests
%files -n python2-m2r
%doc LICENSE README.md
%{python2_sitelib}/{m2r.py{,c,o},m2r-%{version}*-py%{python2_version}.egg-info}
%exclude %{python2_sitelib}/tests
%files -n python3-m2r %files -n python3-m2r
%doc LICENSE README.md %doc LICENSE README.md
%{_bindir}/m2r %{_bindir}/m2r
@ -57,5 +40,8 @@ PYTHONPATH=$(pwd) %{__python3} setup.py test -s tests
%exclude %{python3_sitelib}/tests %exclude %{python3_sitelib}/tests
%changelog %changelog
* Mon Oct 12 2020 maminjie <maminjie1@huawei.com> - 0.1.15-4
* Drop python2 support
* Wed Mar 11 2020 Ling Yang <lingyang2@huawei.com> - 0.1.15-3 * Wed Mar 11 2020 Ling Yang <lingyang2@huawei.com> - 0.1.15-3
- Package Init - Package Init

4
python-m2r.yaml Normal file
View File

@ -0,0 +1,4 @@
version_control: github
src_repo: miyakogi/m2r
tag_prefix: "^v"
seperator: "."