File python-sphinxcontrib-napoleon.spec of Package python-sphinxcontrib-napoleon

#
# spec file for package python-sphinxcontrib-napoleon
#
# # Copyright (c) 2016, Martin Hauke <mardnh@gmx.de>
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/


%define use_build_checks 1

Name:           python-sphinxcontrib-napoleon
Version:        0.5.3
Release:        0
License:        BSD-2-Clause
Summary:        Sphinx napoleon extension
Url:            https://sphinxcontrib-napoleon.readthedocs.io
Group:          Development/Languages/Python
Source:         https://pypi.io/packages/source/s/sphinxcontrib-napoleon/sphinxcontrib-napoleon-%{version}.tar.gz
BuildRequires:  python-devel
BuildRequires:  python-setuptools
%if 0%{?use_build_checks}
BuildRequires:  python-pockets
BuildRequires:  python-Sphinx
BuildRequires:  python-nose
BuildRequires:  python-mock
BuildRequires:  python-flake8
BuildRequires:  python-coverage
%endif
Requires:       python-Sphinx
Requires:       python-six
Requires:       python-pockets
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

%description
Napoleon is a Sphinx extension that parses NumPy and Google style docstrings and
converts them to reStructuredText before Sphinx attempts to parse them.
This happens in an intermediate step while Sphinx is processing the documentation,
so it doesn't modify any of the docstrings in your actual source code files.

%prep
%setup -q -n sphinxcontrib-napoleon-%{version}

%build
python setup.py build

%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
# remove unneeded files
rm -f %{buildroot}/%{python_sitelib}/sphinxcontrib_napoleon-%{version}-py%{py_ver}-nspkg.pth
rm -rf %{buildroot}%{python_sitelib}/tests

%check
%if 0%{?use_build_checks}
python setup.py test
%endif

%files
%defattr(-,root,root,-)
%doc CHANGES LICENSE README.rst
%{python_sitelib}/sphinxcontrib
%{python_sitelib}/sphinxcontrib_napoleon-%{version}-py%{py_ver}.egg-info

%changelog
openSUSE Build Service is sponsored by