File python-PyQRCode.spec of Package python-PyQRCode

#
# spec file for package python-PyQRCode
#
# 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 https://bugs.opensuse.org/
#


%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
%define modname PyQRCode
Name:           python-PyQRCode
Version:        1.2.1
%define sversion 1.2.1+git.20160619.674a77b
Release:        0
Summary:        Python 3 module to generate QR Codes
License:        MIT
URL:            https://github.com/mnooner256/pyqrcode
Source:         pyqrcode-%{sversion}.tar.xz
BuildRequires:  %{python_module Sphinx}
BuildRequires:  %{python_module pypng}
BuildRequires:  %{python_module pytest-runner}
BuildRequires:  %{python_module setuptools}
BuildRequires:  %{python_module pip}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch:      noarch
%python_subpackages

%description
The PyQRCode module is a QR code generator that is simple to use and written in pure python. The module can automates most of the building process for creating QR codes. Most codes can be created using only two lines of code!

%prep
%setup -q -n pyqrcode-%{sversion}

%build
%python_build

%install
%python_install
%python_expand %fdupes %{buildroot}/%{$python_sitelib}

%check
exit 0
%pytest

%files %{python_files}
%license License
%doc README.md Changelog
%{python_sitelib}/*

%changelog
openSUSE Build Service is sponsored by