# Created by pyp2rpm-3.2.2 %global pypi_name doc8 Name: python-%{pypi_name} Version: 0.8.0 Release: 1%{?dist} Summary: Style checker for Sphinx (or other) RST documentation License: None URL: https://launchpad.net/doc8 Source0: https://files.pythonhosted.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch BuildRequires: python2-devel BuildRequires: python-pbr BuildRequires: python-doc8 BuildRequires: python-hacking >= 0.9.2 BuildRequires: python-hacking < 0.10 BuildRequires: python-nose BuildRequires: python-oslo-sphinx BuildRequires: python-sphinx < 1.3 BuildRequires: python-sphinx >= 1.1.2 BuildConflicts: python-sphinx = 1.2.0 BuildRequires: python-testtools BuildRequires: python-setuptools BuildRequires: python-sphinx %description Doc8 Doc8 is an *opinionated* style checker for rst_ (with basic support for plain text) styles of documentation.QuickStart :: pip install doc8To run doc8 just invoke it against any doc directory:: $ doc8 coolproject/docsUsage Command line usage ******************:: $ doc8 h usage: doc8 [h] [config path] [allowlongtitles] [ignore code] [nosphinx] [ignorepath path] [ignorepatherrors path] ... %package -n python2-%{pypi_name} Summary: %{summary} %{?python_provide:%python_provide python2-%{pypi_name}} Requires: python-chardet Requires: python-docutils Requires: python-restructuredtext-lint >= 0.7 Requires: python-six Requires: python-stevedore Requires: python-setuptools %description -n python2-%{pypi_name} Doc8 Doc8 is an *opinionated* style checker for rst_ (with basic support for plain text) styles of documentation.QuickStart :: pip install doc8To run doc8 just invoke it against any doc directory:: $ doc8 coolproject/docsUsage Command line usage ******************:: $ doc8 h usage: doc8 [h] [config path] [allowlongtitles] [ignore code] [nosphinx] [ignorepath path] [ignorepatherrors path] ... %package -n python-%{pypi_name}-doc Summary: doc8 documentation %description -n python-%{pypi_name}-doc Documentation for doc8 %prep %autosetup -n %{pypi_name}-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info %build %py2_build # generate html docs sphinx-build doc/source html # remove the sphinx-build leftovers rm -rf html/.{doctrees,buildinfo} %install %py2_install cp %{buildroot}/%{_bindir}/doc8 %{buildroot}/%{_bindir}/doc8-%{python2_version} ln -s %{_bindir}/doc8-%{python2_version} %{buildroot}/%{_bindir}/doc8-2 %check %{__python2} setup.py test %files -n python2-%{pypi_name} %license LICENSE %doc README.rst doc/source/readme.rst %{_bindir}/doc8 %{_bindir}/doc8-2 %{_bindir}/doc8-%{python2_version} %{python2_sitelib}/%{pypi_name} %{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info %files -n python-%{pypi_name}-doc %doc html %changelog * Sat Jul 22 2017 Copr dist git - 0.8.0-1 - Initial package.