File project.diff of Package git-buildpackage

--- git-buildpackage.changes.orig
+++ git-buildpackage.changes
@@ -1,3 +1,10 @@
+
+-------------------------------------------------------------------
+Tue Mar 14 20:02:47 UTC 2017 - mardnh@gmx.de
+
+- update to version 0.8.13
+- complete specfile overhaul
+
 -------------------------------------------------------------------
 Fri Mar 21 16:54:25 UTC 2014 - jblunck@opensuse.org
 
--- git-buildpackage.spec.orig
+++ git-buildpackage.spec
@@ -1,120 +1,87 @@
-# Add --with docs rpmbuild option, disabled by default
-%bcond_with docs
-
-Name:       git-buildpackage
-Summary:    Build packages from git
-Version:    0.6.10
-Release:    0
-Group:      Development/Tools/Building
-License:    GPLv2
-BuildArch:  noarch
-URL:        https://honk.sigxcpu.org/piki/projects/git-buildpackage/
-Source0:    %{name}-%{version}.tar.bz2
-
-# Conditional package names for requirements
-%if 0%{?fedora} || 0%{?centos_ver}
-%define dpkg_pkg_name dpkg-devel
-%else
-%define dpkg_pkg_name dpkg
-%endif
-
-%if 0%{?suse_version} && 0%{?suse_version} < 1230
-%define devscripts_pkg_name devscripts-fixes
-%else
-%define devscripts_pkg_name devscripts
-%endif
-
-%if 0%{?fedora}
-%define man_pkg_name man-db
-%else
-%define man_pkg_name man
-%endif
-
-%if 0%{?fedora} || 0%{?centos_ver} || 0%{?tizen_version:1}
-%define python_pkg_name python
-%else
-%define python_pkg_name python-base
-%endif
-
-%if 0%{?tizen_version:1}
-%define rpm_python_pkg_name python-rpm
-%else
-%define rpm_python_pkg_name rpm-python
-%endif
-
-Requires:   %{name}-common = %{version}-%{release}
-Requires:   %{dpkg_pkg_name}
-Requires:   %{devscripts_pkg_name}
-BuildRequires:  python
+#
+# spec file for package git-buildpackage
+#
+# Copyright (c) 2017 SUSE LINUX Products GmbH, Nuernberg, Germany.
+#
+# 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 with_docs 1
+%define do_unittests 1
+
+Name:           git-buildpackage
+Version:        0.8.13
+Release:        0
+License:        GPL-2.0+
+Summary:        Suite to help with Debian packages in Git repositories
+Group:          Development/Tools/Other
+Url:            https://honk.sigxcpu.org/piki/projects/git-buildpackage/
+#Git-Clone:     https://git.sigxcpu.org/cgit/git-buildpackage/
+Source:         https://pypi.io/packages/source/g/gbp/gbp-%{version}.tar.gz
+BuildRequires:  python-devel
 BuildRequires:  python-setuptools
-
-%if %{with docs}
+BuildRequires:  python-nosexcover
+BuildRequires:  python-six
+BuildRequires:  python-flake8
+BuildRequires:  rpm-python
+BuildRequires:  python-dateutil
+BuildRequires:  dpkg
+#
+%if 0%{with_docs}
 BuildRequires:  docbook-utils
 BuildRequires:  gtk-doc
 BuildRequires:  epydoc
 %endif
-
+#
 %if 0%{?do_unittests}
 BuildRequires:  python-coverage
 BuildRequires:  python-nose
+BuildRequires:  python-mock
 BuildRequires:  git-core
-BuildRequires:  %{man_pkg_name}
-BuildRequires:  %{dpkg_pkg_name}
-BuildRequires:  %{rpm_python_pkg_name}
+BuildRequires:  man
 BuildRequires:  pristine-tar
 BuildRequires:  unzip
 BuildRequires:  gnupg
-# Missing dep of dpkg in openSUSE
-%if 0%{?suse_version}
+BuildRequires:  libzip
 BuildRequires:  perl-TimeDate
 %endif
-%endif
+#
+Requires:       python
+Requires:       python-six
+Requires:       dpkg
+Requires:       devscripts
+Requires:       git-core
+Requires:       rpm
+Requires:       cpio
+Recommends:     pristine-tar
+Recommends:     python-notify
+Recommends:     unzip
+Recommends:     libzip
+Provides:       gbp
+BuildRoot:      %{_tmppath}/%{name}-%{version}-build
+BuildArch:      noarch
 
 %description
 Set of tools from Debian that integrate the package build system with Git.
 This package contains the original Debian tools.
 
-
-%package common
-Summary:    Common files for git-buildpackage debian and rpm tools
-Group:      Development/Tools/Building
-Requires:   git-core
-Requires:   %{man_pkg_name}
-Requires:   %{python_pkg_name}
-%if 0%{?suse_version} || 0%{?tizen_version:1}
-Recommends:     pristine-tar
-%else
-Requires:       pristine-tar
-Requires:   python-setuptools
-%endif
-
-%description common
-Common files and documentation, used by both git-buildpackage debian and rpm tools
-
-
-%package rpm
-Summary:    Build RPM packages from git
-Group:      Development/Tools/Building
-Requires:   %{name}-common = %{version}-%{release}
-Requires:   rpm
-Requires:   %{rpm_python_pkg_name}
-Provides:   tizen-gbp-rpm = 20140319
-
-%description rpm
-Set of tools from Debian that integrate the package build system with Git.
-This package contains the tools for building RPM packages.
-
-
-
 %prep
-%setup -q -n %{name}-%{version}
-
+%setup -q -n gbp-%{version}
 
 
 %build
-WITHOUT_NOSETESTS=1 python ./setup.py build
+WITHOUT_NOSETESTS=1 python setup.py build
 
-%if %{with docs}
+%if 0%{with_docs}
 # Prepare apidocs
 epydoc -n git-buildpackage --no-sourcecode -o docs/apidocs/ \
     gbp*.py git*.py gbp/
@@ -124,6 +91,19 @@ HAVE_SGML2X=0 make -C docs/
 %endif
 
 
+%install
+WITHOUT_NOSETESTS=1 python setup.py install --prefix=%{_prefix} --root=%{buildroot}
+mkdir -p %{buildroot}/%{_sysconfdir}/git-buildpackage/
+mv %{buildroot}/%{_datadir}/git-buildpackage/gbp.conf %{buildroot}/%{_sysconfdir}/git-buildpackage/gbp.conf
+install -Dpm0644 debian/gbp.completion "%{buildroot}%{_sysconfdir}/bash_completion.d/git-buildpackage.sh"
+%if 0%{with_docs}
+# man pages
+install -d %{buildroot}/%{_mandir}/man1
+install -Dpm0644 docs/*.1 %{buildroot}/%{_mandir}/man1/
+install -d %{buildroot}/%{_mandir}/man5
+install -Dpm0644 docs/*.5 %{buildroot}/%{_mandir}/man5/
+%endif
+
 %if 0%{?do_unittests}
 %check
 GIT_CEILING_DIRECTORIES=%{_builddir} \
@@ -132,67 +112,23 @@ GIT_CEILING_DIRECTORIES=%{_builddir} \
     python setup.py nosetests
 %endif
 
-
-%install
-rm -rf %{buildroot}
-WITHOUT_NOSETESTS=1 python ./setup.py install --root=%{buildroot} --prefix=/usr
-
-cat > files.list << EOF
-%{_bindir}/gbp-pq
-%{_bindir}/git-buildpackage
-%{_bindir}/git-dch
-%{_bindir}/git-import-dsc
-%{_bindir}/git-import-dscs
-%{_bindir}/git-import-orig
-%{_bindir}/git-pbuilder
-%{_bindir}/gbp-create-remote-repo
-%{python_sitelib}/gbp/deb
-%{python_sitelib}/gbp/scripts/pq.py*
-%{python_sitelib}/gbp/scripts/buildpackage.py*
-%{python_sitelib}/gbp/scripts/dch.py*
-%{python_sitelib}/gbp/scripts/import_dsc.py*
-%{python_sitelib}/gbp/scripts/import_dscs.py*
-%{python_sitelib}/gbp/scripts/import_orig.py*
-%{python_sitelib}/gbp/scripts/create_remote_repo.py*
-EOF
-
-# Disable the debian tools for CentOS
-%if 0%{?centos_version}
-for f in `cat files.list`; do
-    rm -rfv %{buildroot}/$f
-done
-
-%else
-
-%files -f files.list
-%defattr(-,root,root,-)
-%endif
-
-%files common
+%files
 %defattr(-,root,root,-)
+%doc README.md
 %{_bindir}/gbp
-%{_bindir}/gbp-clone
-%{_bindir}/gbp-pull
-%dir %{python_sitelib}/gbp
-%dir %{python_sitelib}/gbp/git
-%dir %{python_sitelib}/gbp/pkg
-%dir %{python_sitelib}/gbp/scripts
-%dir %{python_sitelib}/gbp/scripts/common
-%{python_sitelib}/gbp-*.egg-info
-%{python_sitelib}/gbp/*.py*
-%{python_sitelib}/gbp/scripts/__init__.py*
-%{python_sitelib}/gbp/scripts/clone.py*
-%{python_sitelib}/gbp/scripts/pull.py*
-%{python_sitelib}/gbp/scripts/supercommand.py*
-%{python_sitelib}/gbp/scripts/common/*.py*
-%{python_sitelib}/gbp/git/*.py*
-%{python_sitelib}/gbp/pkg/*.py*
-%config %{_sysconfdir}/git-buildpackage
-
+%{_bindir}/git-pbuilder
+%{_bindir}/gbp-builder-mock
+%dir %{_sysconfdir}/git-buildpackage
+%config %{_sysconfdir}/git-buildpackage/gbp.conf
+%if 0%{with_docs}
+%{_mandir}/man?/*%{ext_man}
+%{_mandir}/man1/gbp-*1%{ext_man}
+%{_mandir}/man1/gbp.1%{ext_man}
+%{_mandir}/man1/git-pbuilder.1%{ext_man}
+%{_mandir}/man5/gbp.conf.5%{ext_man}
+%endif
+%{python_sitelib}/gbp
+%{python_sitelib}/gbp-%{version}-py%{py_ver}.egg-info
+%{_sysconfdir}/bash_completion.d/git-buildpackage.sh
 
-%files rpm
-%defattr(-,root,root,-)
-%dir %{python_sitelib}/gbp/rpm
-%{_bindir}/*rpm*
-%{python_sitelib}/gbp/scripts/*rpm*.py*
-%{python_sitelib}/gbp/rpm/*py*
+%changelog
openSUSE Build Service is sponsored by