File python-osc-lib.spec of Package python-osc-lib

# spec file for package python-osc-lib
# Copyright (c) 2020 SUSE LLC
# 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

Name:           python-osc-lib
Version:        1.11.1
Release:        0
Summary:        OpenStackClient Library
License:        Apache-2.0
Group:          Development/Languages/Python
Patch1:         0001-Fix-formatter-handling-for-python-3.7.patch
BuildRequires:  openstack-macros
BuildRequires:  python-devel
BuildRequires:  python2-Babel
BuildRequires:  python2-cliff
BuildRequires:  python2-fixtures
BuildRequires:  python2-keystoneauth1
BuildRequires:  python2-mock
BuildRequires:  python2-openstacksdk
BuildRequires:  python2-os-client-config
BuildRequires:  python2-os-testr
BuildRequires:  python2-oslo.i18n
BuildRequires:  python2-oslo.utils
BuildRequires:  python2-oslotest
BuildRequires:  python2-osprofiler
BuildRequires:  python2-pbr
BuildRequires:  python2-requests-mock
BuildRequires:  python2-simplejson
BuildRequires:  python2-six
BuildRequires:  python2-stestr
BuildRequires:  python2-stevedore
BuildRequires:  python2-testtools
BuildRequires:  python3-Babel
BuildRequires:  python3-cliff
BuildRequires:  python3-devel
BuildRequires:  python3-fixtures
BuildRequires:  python3-keystoneauth1
BuildRequires:  python3-mock
BuildRequires:  python3-openstacksdk
BuildRequires:  python3-os-client-config
BuildRequires:  python3-os-testr
BuildRequires:  python3-oslo.i18n
BuildRequires:  python3-oslo.utils
BuildRequires:  python3-oslotest
BuildRequires:  python3-osprofiler
BuildRequires:  python3-pbr
BuildRequires:  python3-requests-mock
BuildRequires:  python3-simplejson
BuildRequires:  python3-six
BuildRequires:  python3-stestr
BuildRequires:  python3-stevedore
BuildRequires:  python3-testtools
Requires:       python-Babel
Requires:       python-cliff
Requires:       python-keystoneauth1
Requires:       python-openstacksdk
Requires:       python-os-client-config
Requires:       python-oslo.i18n
Requires:       python-oslo.utils
Requires:       python-pbr
Requires:       python-simplejson
Requires:       python-six
Requires:       python-stevedore
BuildArch:      noarch

OpenStackClient (aka OSC) is a command-line client for OpenStack.  osc-lib
is a package of common support modules for writing OSC plugins.

%package -n python-osc-lib-doc
Summary:        Documentation for the OpenStack client library
Group:          Development/Languages/Python
BuildRequires:  python-Sphinx
BuildRequires:  python-openstackdocstheme
BuildRequires:  python-reno
BuildRequires:  python-sphinxcontrib-apidoc

%description -n python-osc-lib-doc
Documentation for the OpenStack client library.

%autosetup -p1 -n osc-lib-1.11.1
sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg



# generate html docs
PBR_VERSION=%version PYTHONPATH=. sphinx-build -a -E -d doc/build/doctrees -b html doc/source doc/build/html
# remove the sphinx-build leftovers
rm -rf doc/build/html/.{doctrees,buildinfo}

%python_exec -m stestr.cli run

%files %{python_files}
%license LICENSE
%doc README.rst ChangeLog

%files -n python-osc-lib-doc
%license LICENSE
%doc doc/build/html

openSUSE Build Service is sponsored by