Blob Blame History Raw
%global pypi_name py-gfm

Name:           python-gfm
Version:        0.1.3
Release:        9%{?dist}
Summary:        Github-Flavored Markdown for Python-Markdown
License:        BSD
URL:            https://github.com/Zopieux/py-gfm
Source0:        https://files.pythonhosted.org/packages/source/%(n=%{pypi_name}; echo ${n:0:1})/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
# Missing LICENSE file in pypi package reported at https://github.com/Zopieux/py-gfm/issues/5
Source1:        https://github.com/Zopieux/py-gfm/blob/master/LICENSE


BuildArch:      noarch
BuildRequires:  python2-devel
%if 0%{?fedora}
BuildRequires:  python2-markdown
BuildRequires:  python2-setuptools
%else
BuildRequires:  python-markdown
BuildRequires:  python-setuptools
%endif
BuildRequires:  python%{python3_pkgversion}-devel
BuildRequires:  python%{python3_pkgversion}-markdown
BuildRequires:  python%{python3_pkgversion}-setuptools


%description
This is an implementation of GitHub-Flavored Markdown written as an extension
to the Python Markdown library. It aims for maximal compatibility with GitHub's
rendering.


%package -n python2-gfm
Summary:        %{summary}
%{?python_provide:%python_provide python2-gfm}
%if 0%{?fedora}
Requires:  python2-markdown
%else
Requires:  python-markdown
%endif
%description -n python2-gfm
This is an implementation of GitHub-Flavored Markdown written as an extension
to the Python Markdown library. It aims for maximal compatibility with GitHub's
rendering.


%package -n python%{python3_pkgversion}-gfm
Summary:        %{summary}
%{?python_provide:%python_provide python%{python3_pkgversion}-gfm}
Requires:  python%{python3_pkgversion}-markdown
%description -n python%{python3_pkgversion}-gfm
This is an implementation of GitHub-Flavored Markdown written as an extension
to the Python Markdown library. It aims for maximal compatibility with GitHub's
rendering.


%prep
%setup -q -n %{pypi_name}-%{version}
cp %{SOURCE1} .


%build
%py2_build
%py3_build


%install
%py2_install
%py3_install


%check
%{__python2} setup.py test
%{__python3} setup.py test


%files -n python2-gfm
%license LICENSE
%doc README.rst
%{python2_sitelib}/*


%files -n python%{python3_pkgversion}-gfm
%license LICENSE
%doc README.rst
%{python3_sitelib}/*


%changelog
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.3-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild

* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.1.3-8
- Rebuilt for Python 3.7

* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.3-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.3-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild

* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.3-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild

* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 0.1.3-4
- Rebuild for Python 3.6

* Sat Oct 29 2016 Germano Massullo <germano.massullo@gmail.com> - 0.1.3-3
- Added macro %{python3_pkgversion} to allow Python 3 builds on EPEL7

* Fri Aug 19 2016 Thomas Moschny <thomas.moschny@gmx.de> - 0.1.3-2
- Spec file cleanup, allow building on EPEL7.

* Wed Aug 10 2016 Germano Massullo <germano.massullo@gmail.com> - 0.1.3-1
- First commit on Fedora's Git