--- Begin Message ---
Package: git-buildpackage
Version: 0.9.22
Severity: wishlist
Tags: patch
Hello.
The attached commits may slightly help the maintainance of the Debian
packaging.
Please apply the ones you agree with.
Thanks.
>From e3ffa388e72450a6fbb37800a69d1094aafdc55d Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 14:54:08 +0200
Subject: [PATCH 1/8] debhelper: make package prefix explicit in configuration
files
This slightly improves readability.
---
debian/{doc-base => git-buildpackage.doc-base} | 0
debian/{docs => git-buildpackage.docs} | 0
debian/{examples => git-buildpackage.examples} | 0
debian/{links => git-buildpackage.links} | 0
4 files changed, 0 insertions(+), 0 deletions(-)
rename debian/{doc-base => git-buildpackage.doc-base} (100%)
rename debian/{docs => git-buildpackage.docs} (100%)
rename debian/{examples => git-buildpackage.examples} (100%)
rename debian/{links => git-buildpackage.links} (100%)
diff --git a/debian/doc-base b/debian/git-buildpackage.doc-base
similarity index 100%
rename from debian/doc-base
rename to debian/git-buildpackage.doc-base
diff --git a/debian/docs b/debian/git-buildpackage.docs
similarity index 100%
rename from debian/docs
rename to debian/git-buildpackage.docs
diff --git a/debian/examples b/debian/git-buildpackage.examples
similarity index 100%
rename from debian/examples
rename to debian/git-buildpackage.examples
diff --git a/debian/links b/debian/git-buildpackage.links
similarity index 100%
rename from debian/links
rename to debian/git-buildpackage.links
--
2.30.2
>From 31c177f2ad1177ae9872975c7dc15fb5c697314c Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:02:13 +0200
Subject: [PATCH 2/8] debian/rules: simplify installation of zsh and pk4
There seems to be no reason to change their names and permissions
between the source tree and the eventual installation path.
---
debian/git-buildpackage.install | 2 ++
debian/{pk4 => pk4/gbp} | 0
debian/rules | 9 ---------
debian/{git-buildpackage.zsh-completion => zsh/_gbp} | 0
4 files changed, 2 insertions(+), 9 deletions(-)
rename debian/{pk4 => pk4/gbp} (100%)
mode change 100644 => 100755
rename debian/{git-buildpackage.zsh-completion => zsh/_gbp} (100%)
diff --git a/debian/git-buildpackage.install b/debian/git-buildpackage.install
index 8e898c17..956ac8c3 100644
--- a/debian/git-buildpackage.install
+++ b/debian/git-buildpackage.install
@@ -1,3 +1,5 @@
+debian/zsh/_gbp usr/share/zsh/vendor-completions
+debian/pk4/gbp usr/share/pk4/hooks-available/unpack
usr/bin/gbp
usr/bin/git-pbuilder
usr/lib/python3.*/dist-packages/gbp-* usr/lib/python3/dist-packages/
diff --git a/debian/pk4 b/debian/pk4/gbp
old mode 100644
new mode 100755
similarity index 100%
rename from debian/pk4
rename to debian/pk4/gbp
diff --git a/debian/rules b/debian/rules
index 24dedb6c..c49d2c2e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,9 +9,6 @@ EXAMPLE_SCRIPTS=\
DEB_COMPRESS_EXCLUDE=$(EXAMPLE_SCRIPTS)
-ZSH_COMPDIR = /usr/share/zsh/vendor-completions/
-PK4_DIR = /usr/share/pk4/hooks-available/unpack/
-
PYCHECKER_ARGS=-boptparse --no-override --no-shadowbuiltin
%:
@@ -31,12 +28,6 @@ override_dh_auto_build:
override_dh_auto_install:
dh_auto_install
dh_bash-completion
- mkdir -p debian/git-buildpackage/$(ZSH_COMPDIR)
- install -m644 debian/git-buildpackage.zsh-completion \
- debian/git-buildpackage/$(ZSH_COMPDIR)/_gbp
- mkdir -p debian/git-buildpackage/$(PK4_DIR)
- install -m755 debian/pk4 \
- debian/git-buildpackage/$(PK4_DIR)/gbp
chmod a+x debian/tmp/usr/lib/python3.*/dist-packages/gbp/scripts/supercommand.py
override_dh_auto_clean:
diff --git a/debian/git-buildpackage.zsh-completion b/debian/zsh/_gbp
similarity index 100%
rename from debian/git-buildpackage.zsh-completion
rename to debian/zsh/_gbp
--
2.30.2
>From a37e989709635d46e4ca17a4e2c6bfdea0614463 Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:13:06 +0200
Subject: [PATCH 3/8] rules: simplify thanks to debhelper compat 13
When dh-sequence-foo is listed in build-depends, debhelper
automatically inserts dh_foo in the commands.
override_dh_auto_test is not invoked anymore if DEB_BUILD_OPTIONS
contains nocheck.
execute_after_dh_* is available and more readable than override_dh_*.
Move chmod to execute_after_dh_fixperms for clarity.
Examples are not compressed anymore.
---
debian/control | 1 +
debian/rules | 22 ++++++----------------
2 files changed, 7 insertions(+), 16 deletions(-)
diff --git a/debian/control b/debian/control
index ab89dc58..0997139e 100644
--- a/debian/control
+++ b/debian/control
@@ -6,6 +6,7 @@ Build-Depends:
bash-completion (>= 1:2.1-4.2~),
debhelper-compat (= 13),
dh-python,
+ dh-sequence-bash-completion,
dh-sequence-python3,
docbook2x,
flake8,
diff --git a/debian/rules b/debian/rules
index c49d2c2e..381be217 100755
--- a/debian/rules
+++ b/debian/rules
@@ -11,30 +11,20 @@ DEB_COMPRESS_EXCLUDE=$(EXAMPLE_SCRIPTS)
PYCHECKER_ARGS=-boptparse --no-override --no-shadowbuiltin
+
%:
- dh $@ --with python3 --buildsystem=pybuild
+ dh $@ --buildsystem=pybuild
override_dh_auto_test:
-ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
make
-else
- @echo "Checks disabled via DEB_BUILD_OPTIONS"
-endif
-override_dh_auto_build:
- dh_auto_build
+execute_after_dh_auto_build:
make docs
-override_dh_auto_install:
- dh_auto_install
- dh_bash-completion
- chmod a+x debian/tmp/usr/lib/python3.*/dist-packages/gbp/scripts/supercommand.py
+execute_after_dh_fixperms:
+ chmod a+x debian/git-buildpackage/usr/lib/python3/dist-packages/gbp/scripts/supercommand.py
-override_dh_auto_clean:
- dh_auto_clean
+execute_after_dh_auto_clean:
rm -rf build/
make -C docs/ clean
-rm gbp/version.py
-
-override_dh_compress:
- dh_compress --exclude=usr/share/doc/git-buildpackage/examples/
--
2.30.2
>From ad3038ea6adcd45a465e968139ebfae2d8a8a811 Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:17:12 +0200
Subject: [PATCH 4/8] debian/rules: remove obsolete and unused Make variables
---
debian/rules | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/debian/rules b/debian/rules
index 381be217..0802452d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,17 +1,5 @@
#!/usr/bin/make -f
-EXAMPLE_SCRIPTS=\
- gbp-add-patch \
- gbp-cowbuilder-sid \
- gbp-posttag-push \
- gbp-configure-unpatched-source \
- wrap_cl.py
-
-DEB_COMPRESS_EXCLUDE=$(EXAMPLE_SCRIPTS)
-
-PYCHECKER_ARGS=-boptparse --no-override --no-shadowbuiltin
-
-
%:
dh $@ --buildsystem=pybuild
--
2.30.2
>From abe60648586d3711c533e016137aead8c25fc67e Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:27:41 +0200
Subject: [PATCH 5/8] debhelper: generate some lists in configuration files
---
debian/clean | 9 ++++++
debian/git-buildpackage-rpm.install | 13 +++++----
debian/git-buildpackage.install | 43 ++++++-----------------------
debian/not-installed | 11 +++-----
debian/rules | 2 --
5 files changed, 29 insertions(+), 49 deletions(-)
create mode 100755 debian/clean
mode change 100644 => 100755 debian/git-buildpackage-rpm.install
mode change 100644 => 100755 debian/git-buildpackage.install
mode change 100644 => 100755 debian/not-installed
diff --git a/debian/clean b/debian/clean
new file mode 100755
index 00000000..55f56593
--- /dev/null
+++ b/debian/clean
@@ -0,0 +1,9 @@
+#!/bin/sh
+set -C -e -f -u
+
+find gbp -name __init__.py -printf '%h/__pycache__/\n'
+
+cat <<EOF
+
+build/
+gbp/version.py
diff --git a/debian/git-buildpackage-rpm.install b/debian/git-buildpackage-rpm.install
old mode 100644
new mode 100755
index f79d4f17..755410d1
--- a/debian/git-buildpackage-rpm.install
+++ b/debian/git-buildpackage-rpm.install
@@ -1,6 +1,9 @@
+#!/bin/sh
+set -C -e -f -u
+
+find gbp -path '*rpm*.py' -printf \
+ 'usr/lib/python3.*/dist-packages/%p usr/lib/python3/dist-packages/%h\n'
+
+cat <<EOF
+
usr/bin/gbp-builder-mock /usr/share/git-buildpackage/
-usr/lib/python3.*/dist-packages/gbp/rpm usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*//dist-packages/gbp/scripts/import_srpm.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/pq_rpm.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/buildpackage_rpm.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/rpm_ch.py usr/lib/python3/dist-packages/gbp/scripts/
diff --git a/debian/git-buildpackage.install b/debian/git-buildpackage.install
old mode 100644
new mode 100755
index 956ac8c3..2a34b97a
--- a/debian/git-buildpackage.install
+++ b/debian/git-buildpackage.install
@@ -1,41 +1,14 @@
+#!/bin/sh
+set -C -e -f -u
+
+find gbp -name '*.py' -a ! -path '*rpm*' -printf \
+ 'usr/lib/python3.*/dist-packages/%p usr/lib/python3/dist-packages/%h\n'
+
+cat <<EOF
+
debian/zsh/_gbp usr/share/zsh/vendor-completions
debian/pk4/gbp usr/share/pk4/hooks-available/unpack
usr/bin/gbp
usr/bin/git-pbuilder
usr/lib/python3.*/dist-packages/gbp-* usr/lib/python3/dist-packages/
-usr/lib/python3.*/dist-packages/gbp/command_wrappers.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/config.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/dch.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/deb/ usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/errors.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/format.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/git/ usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/__init__.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/log.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/notifications.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/paths.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/patch_series.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/pkg/ usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/scripts/buildpackage.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/clone.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/common/ usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/config.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/create_remote_repo.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/dch.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/import_dsc.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/import_dscs.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/import_orig.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/import_ref.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/export_orig.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/__init__.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/pq.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/pristine_tar.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/pull.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/push.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/setup_gitattributes.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/supercommand.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/scripts/tag.py usr/lib/python3/dist-packages/gbp/scripts/
-usr/lib/python3.*/dist-packages/gbp/tmpfile.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/tristate.py usr/lib/python3/dist-packages/gbp/
-usr/lib/python3.*/dist-packages/gbp/version.py usr/lib/python3/dist-packages/gbp/
usr/share/git-buildpackage/gbp.conf etc/git-buildpackage/
diff --git a/debian/not-installed b/debian/not-installed
old mode 100644
new mode 100755
index 0a7a6e06..55a402ae
--- a/debian/not-installed
+++ b/debian/not-installed
@@ -1,8 +1,5 @@
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/deb/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/git/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/pkg/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/rpm/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/scripts/common/__pycache__
-debian/tmp/usr/lib/python3.*/dist-packages/gbp/scripts/__pycache__
+#!/bin/sh
+set -C -e -f -u
+find gbp -name __init__.py -printf \
+ 'usr/lib/python3.*/dist-packages/%h/__pycache__\n'
diff --git a/debian/rules b/debian/rules
index 0802452d..ad61ba7a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -13,6 +13,4 @@ execute_after_dh_fixperms:
chmod a+x debian/git-buildpackage/usr/lib/python3/dist-packages/gbp/scripts/supercommand.py
execute_after_dh_auto_clean:
- rm -rf build/
make -C docs/ clean
- -rm gbp/version.py
--
2.30.2
>From 975f88e02f487762dc215f5a0b518b1c8388616d Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:29:37 +0200
Subject: [PATCH 6/8] debian/clean: add forgotten files
---
debian/clean | 3 +++
1 file changed, 3 insertions(+)
diff --git a/debian/clean b/debian/clean
index 55f56593..5fa088cf 100755
--- a/debian/clean
+++ b/debian/clean
@@ -6,4 +6,7 @@ find gbp -name __init__.py -printf '%h/__pycache__/\n'
cat <<EOF
build/
+coverage.xml
+gbp.egg-info/
gbp/version.py
+nosetests.xml
--
2.30.2
>From e9df4ce338354bf7dc965cd445308e1a1b751b69 Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:30:22 +0200
Subject: [PATCH 7/8] Makefile: spare unneeded recursive Make invokations
Also, export GBP_NETWORK_TESTS so that it is actually seen by
tests/*.py.
---
Makefile | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/Makefile b/Makefile
index db5ad88e..b97ad640 100644
--- a/Makefile
+++ b/Makefile
@@ -5,8 +5,8 @@ TEST_LOCALE?=C.UTF-8
all: syntax-check test
-all+net:
- $(MAKE) GBP_NETWORK_TESTS=1 all
+all+net: export GBP_NETWORK_TESTS := 1
+all+net: all
test:
export HOME=/nonexisting; \
@@ -22,9 +22,8 @@ syntax-check:
flake8 $(FLAKE_OPTS)
flake8 $(FLAKE_OPTS) $(PY_EXAMPLES)
-docs:
+docs: apidocs
$(MAKE) -C docs
- $(MAKE) apidocs
apidocs:
mkdir -p build
--
2.30.2
>From e84e58c2678d77b2a6ff634c04e7e6750d054fc3 Mon Sep 17 00:00:00 2001
From: Nicolas Boulenguez <nico...@debian.org>
Date: Tue, 17 May 2022 15:53:15 +0200
Subject: [PATCH 8/8] debian/copyrigt: switch to machine-readable format 1.0
---
debian/copyright | 54 +++++++++++++++++++++---------------------------
1 file changed, 24 insertions(+), 30 deletions(-)
diff --git a/debian/copyright b/debian/copyright
index 32a20193..d7fd7ce8 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -1,30 +1,24 @@
-This package was debianized by Guido Günther <a...@sigxcpu.org> on
-Tue, 12 Sep 2006 14:55:57 +0200.
-
-It was downloaded from https://honk.sigxcpu.org/piki/projects/git-buildpackage/
-
-Upstream Author: Guido Günther <a...@sigxcpu.org>
-
-Copyright: 2006,2007,2008,2009,2010, Guido Günther
-
-License:
-
-You are free to distribute this software under the terms of the GNU General
-Public License Version 2. The full text of this license can be found in the
-file /usr/share/common-licenses/GPL-2
-
-Git-buildpackage includes git-pbuilder written by Russ Allbery
-<r...@stanford.edu>
-
-Copyright: 2008, 2009, 2010 Board of Trustees, Leland Stanford Jr. University
-License:
-
-Permission to use, copy, modify, and distribute this software and its
-documentation for any purpose and without fee is hereby granted, provided
-that the above copyright notice appear in all copies and that both that
-copyright notice and this permission notice appear in supporting
-documentation, and that the name of Stanford University not be used in
-advertising or publicity pertaining to distribution of the software without
-specific, written prior permission. Stanford University makes no
-representations about the suitability of this software for any purpose. It
-is provided "as is" without express or implied warranty.
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+
+Files: *
+Copyright:
+ 2006-2022 Guido Günther <a...@sigxcpu.org>
+License: GPL-2
+ You are free to distribute this software under the terms of the GNU General
+ Public License Version 2. The full text of this license can be found in the
+ file /usr/share/common-licenses/GPL-2
+
+Files: bin/git-pbuilder
+Copyright:
+ 2014-2016 Russ Allbery <r...@stanford.edu>
+ 2008-2013 The Board of Trustees of the Leland Stanford Junior University
+License: expat-variant
+ Permission to use, copy, modify, and distribute this software and its
+ documentation for any purpose and without fee is hereby granted, provided
+ that the above copyright notice appear in all copies and that both that
+ copyright notice and this permission notice appear in supporting
+ documentation, and that the name of Stanford University not be used in
+ advertising or publicity pertaining to distribution of the software without
+ specific, written prior permission. Stanford University makes no
+ representations about the suitability of this software for any purpose. It
+ is provided "as is" without express or implied warranty.
--
2.30.2
--- End Message ---