+git-buildpackage (0.8.14) experimental; urgency=medium
+
+ gbp import-orig's --merge-mode option now defaults to 'auto' selecting
+ 'replace' for 3.0 (quilt) packages and 'merge' otherwise. If you want to
+ retain the old behaviour of 'merge' please do so in gbp.conf.
+
+ -- Guido Günther <agx@sigxcpu.org> Tue, 04 Apr 2017 07:20:04 +0200
+
+git-buildpackage (0.6.26) unstable; urgency=medium
+
+ All gbp-* and git-* commands are now gone as announced in the
+ deprecation notice from June 2013. From now on only "gbp <command>" is
+ supported.
+
+ -- Guido Günther <agx@sigxcpu.org> Mon, 27 Apr 2015 21:55:23 +0200
+
git-buildpackage (0.6.9) unstable; urgency=medium
This version changes the default of the cleaner options from 'debuild clean'
git-buildpackage (0.4.61) unstable; urgency=low
- In order to not override dpkg-buildpackge's defaults for 3.0 source packages
+ In order to not override dpkg-buildpackage's defaults for 3.0 source packages
the default builder command is now "debuild -i -I" instead of "debuild
-i\.git/ -I.git". If you want to retain the old behaviour please adjust your
gbp.conf accordingly.
--- /dev/null
+build/
+coverage.xml
+gbp.egg-info/
+gbp/version.py
+nosetests.xml
Priority: optional
Maintainer: Guido Günther <agx@sigxcpu.org>
Build-Depends:
- bash-completion,
+ bash-completion (>= 1:2.1-4.2~),
+ debhelper-compat (= 13),
dh-python,
- debhelper (>= 9~),
- docbook-utils,
+ dh-sequence-bash-completion,
+ dh-sequence-python3,
+ docbook2x,
+ flake8,
gtk-doc-tools,
- openjade,
+ libdistro-info-perl,
perl,
+ pydoctor,
python3,
- python-epydoc | pydoctor | python-pydoctor,
+ python3-coverage,
+ python3-dateutil,
+ python3-filelock,
+ python3-mock,
python3-nose,
+ python3-nosexcover,
python3-pkg-resources,
+ python3-rpm,
python3-setuptools,
- python3-dateutil,
- sgml2x,
- librpm-tizen,
-# For rpm (epydoc)
- python3-rpm
-Standards-Version: 3.9.4
-Vcs-Git: git://honk.sigxcpu.org/git/git-buildpackage.git
-Vcs-Browser: https://honk.sigxcpu.org/gitweb/?p=git-buildpackage.git
+ python3-yaml,
+ xsltproc,
+# For the testsuite
+ bzip2 <!nocheck>,
+ cpio <!nocheck>,
+ devscripts (>= 2.17.7~) <!nocheck>,
+ git (>= 1:1.7.9.1-1~) <!nocheck>,
+ pristine-tar (>= 1.14) <!nocheck>,
+ rpm (>= 4.16.1) <!nocheck>,
+ unzip <!nocheck>,
+ zipmerge <!nocheck>,
+# For the network tests
+ curl <!nocheck>,
+ python3-requests <!nocheck>,
+Standards-Version: 4.4.0
+Vcs-Git: https://git.sigxcpu.org/cgit/git-buildpackage/
+Vcs-Browser: https://git.sigxcpu.org/cgit/git-buildpackage/
Homepage: https://honk.sigxcpu.org/piki/projects/git-buildpackage/
-X-Python3-Version: >= 3.5
-
+Rules-Requires-Root: no
+X-Python3-Version: >= 3.7
-Package: git-buildpackage-common
+Package: git-buildpackage
Architecture: all
Depends: ${python3:Depends},
${shlibs:Depends},
devscripts (>= 2.13.5~),
git (>= 1:1.7.9.1-1~),
man-db,
- python3-pkg-resources,
python3-dateutil,
-#unittest need
- zipmerge
-Recommends: pristine-tar (>= 0.5)
-Suggests: python3-notify2, unzip, zipmerge
-Description: Suite to help with packaging in Git repositories
- This package contains the common API and scripts for Debian and rpm packaging
-
-Package: git-buildpackage
-Architecture: all
-Depends: ${python3:Depends},
- ${shlibs:Depends},
- ${misc:Depends},
- devscripts,
- git-buildpackage-common (= ${binary:Version})
-Recommends: cowbuilder
+ python3-pkg-resources,
+ python3-yaml,
+ sensible-utils,
+Recommends: pristine-tar (>= 1.41),
+ cowbuilder | pbuilder | sbuild,
+ python3-requests
+Breaks: dgit (<< 9.16~)
+Suggests: python3-notify2, unzip, sudo
Description: Suite to help with Debian packages in Git repositories
This package contains the following tools:
- * gbp import-{dsc,dscs}: import existing Debian source packages into a git
- repository
- * gbp import-orig: import a new upstream version into the git repository
- * gbp buildpackage: build a package out of a git repository, check for local
+ * gbp buildpackage: build a package out of a Git repository, check for local
modifications and tag appropriately
+ * gbp import-orig: import a new upstream version into the Git repository
+ * gbp export-orig: export an upstream tarball from the Git repository
+ * gbp import-{dsc,dscs}: import existing Debian source packages into a Git
+ repository
* gbp dch: generate Debian changelog entries from Git commit messages
* gbp {pull,clone}: clone and pull from remote repos
* gbp pq: manage debian/patches easily
* gbp create-remote-repo: create remote repositories
+ * gbp push: push content to remote repositories
+ * gbp tag: tag a Debian package in Git
+ * gbp pristine-tar: create pristine-tar commits
+ * gbp setup-gitattributes: set up Git attributes to disable transformations
Package: git-buildpackage-rpm
Architecture: all
Depends: ${python3:Depends},
- ${shlibs:Depends},
${misc:Depends},
- python3-rpm,
- rpm2cpio,
- git-buildpackage-common (= ${binary:Version})
-Recommends: rpm
-Description: Suite to help with rpm packages in Git repositories
+ cpio,
+ git-buildpackage (= ${binary:Version}),
+ python3-rpm (>= 4.16.1),
+ rpm (>= 4.16.1),
+Recommends: pristine-tar (>= 0.5)
+Suggests: python3-notify, unzip, zipmerge, mock
+Description: Suite to help with RPM packages in Git repositories
This package contains the following tools:
- * git-import-srpm: import existing rpm source packages into a git
+ * gbp buildpackage-rpm: build a package out of a Git repository, check for
+ local modifications and tag appropriately
+ * gbp import-srpm: import existing RPM source packages into a Git
repository
- * git-import-orig-rpm: import a new upstream version into the git repository
- * git-buildpackage-rpm: build a package out of a git repository, check for local
- modifications and tag appropriately
- * gbp-pq-rpm: manage separate development and packaging branches
-
-Package: git-buildpackage-bb
-Architecture: all
-Depends: ${python3:Depends},
- ${misc:Depends},
- git-buildpackage-common (= ${binary:Version}),
- git-buildpackage-rpm (= ${binary:Version}),
-Recommends: bitbake
-Description: Suite to help with BitBake builds from Git repositories
- This package contains the following tools:
- * gbp import-bb: import sources from distribution repository
- * gbp buildpackage-bb: build a package out of a Git repository
- * gbp pq-bb: manage separate development and packaging branches
+ * gbp pq-rpm: manage patches easily
+ .
+ These tools are currently in an experimental state. Branch names and
+ repository layouts might change without lots of prior warning.
-This package was debianized by Guido Günther <agx@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 <agx@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
-<rra@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 <agx@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 <rra@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.
--- /dev/null
+# -*- shell-script -*-
+#
+# Bash tab auto-completion rules for git-buildpackage.
+#
+# Copyright (C) 2010 Siegfried-Angel Gevatter Pujals <siegfried@gevatter.com>
+# Copyright (C) 2010,2013,2015 Guido Günther <agx@sigxcpu.org>
+#
+# Distributed under the GNU General Public License, version 2.0.
+
+_gbp_branches ()
+{
+ [ -d .git ] || return 0
+ git for-each-ref --format="%(refname:short)" refs/heads
+}
+
+
+_gbp_tags ()
+{
+ [ -d .git ] || return 0
+ git for-each-ref --format="%(refname:short)" refs/tags
+}
+
+
+_gbp_remote_configs ()
+{
+ GBP_DISABLE_GBP_CONF_DEPRECATION=true \
+ GBP_DISABLE_SECTION_DEPRECATION=true \
+ gbp create-remote-repo list | sed -ne 's/^ \+\([a-z]\+\)/\1/p'
+}
+
+
+_gbp_options ()
+{
+ GBP_DISABLE_GBP_CONF_DEPRECATION=true \
+ GBP_DISABLE_SECTION_DEPRECATION=true \
+ gbp "${1}" --help | sed -ne 's/^ \+\(\(\-[a-z]\), \)\?\(\-\-[a-z\-]\+\=\?\).*/\2 \3/p'
+}
+
+
+_gbp_commands ()
+{
+ gbp --list-cmds | sed -ne 's/^ \+\([a-z\-]\+\) \-.*/\1/p'
+}
+
+
+_gbp_comp ()
+{
+ local cur="${COMP_WORDS[COMP_CWORD]}"
+ local prev="${COMP_WORDS[COMP_CWORD - 1]}"
+ local options=$1
+ local branch_opts=${2:-"--debian-branch\= --upstream-branch\= --upstream-tree\="}
+ local tag_opts=${3:-"--debian-tag\= --upstream-tag\= --upstream-vcs-tag\="}
+ local tristate_opts=${4:-"--color\="}
+ local cbdist_opts=${5:-"--git-dist\="}
+ local remote_config_opts="--remote-config\="
+ local file_opts="--postimport\= --git-builder\= --git-cleaner\= \
+ --git-export-dir\= --git-postbuild\= --git-postexport\= \
+ --git-posttag\= --git-prebuild\= --git-preexport\= --git-tarball-dir\= \
+ --posttag\= --tarball-dir\="
+ local start_opt=""
+
+# COMPREPLY considers '=' as a word. For $prev we prefer the word before the actual "="
+ if [[ "$prev" == "=" ]]; then
+ prev="${COMP_WORDS[COMP_CWORD - 2]}"
+ elif [[ "$cur" == "=" ]]; then
+ start_opt=1
+ cur=""
+ fi
+
+ if [[ ${prev} == --* ]]; then
+ if [[ "${branch_opts}" == *$prev* && "${prev}" == --* ]]; then
+ local refs=$(_gbp_branches)
+ COMPREPLY=( $(compgen -W "$refs" -- $cur ) )
+ return 0
+ fi
+
+ if [[ "${tag_opts}" == *$prev* && "${prev}" == --* ]]; then
+ local refs=$(_gbp_tags)
+ COMPREPLY=( $(compgen -W "$refs" -- $cur ) )
+ return 0
+ fi
+
+ if [[ "${tristate_opts}" == *$prev* ]]; then
+ COMPREPLY=( $(compgen -W 'on off auto' -- $cur ) )
+ return 0
+ fi
+
+ if [[ "${cbdist_opts}" == *$prev* ]]; then
+ local BASE="/var/cache/pbuilder/base-"
+ COMPREPLY=( $( compgen -o dirnames -G "${BASE}${cur}*.cow" \
+ | sed -e "s,${BASE}\(.*\)\.cow,\1,g" ) )
+ return 0
+ fi
+
+ if [[ "${remote_config_opts}" == *$prev* ]]; then
+ local remote_configs=$(_gbp_remote_configs)
+ COMPREPLY=( $(compgen -W "$remote_configs" -- $cur ) )
+ return 0
+ fi
+
+ if [[ "${file_opts}" == *$prev* ]]; then
+ COMPREPLY=( $(compgen -f -- $cur ) )
+ return 0
+ fi
+ fi
+
+ # separate opts by tab so we can append a space to all options not ending
+ # with an equal sign
+ tab_opts=$(echo "$options" | sed -e 's/ \+/\t/g' -e 's/[^=]$/& /g')
+ type compopt &>/dev/null && compopt -o nospace
+ local IFS=$'\t\n'
+ if [ -n "$start_opt" ]; then
+ COMPREPLY="" # we don't have any good suggestions
+ else
+ COMPREPLY=($(compgen -W "$tab_opts" -- $cur))
+ fi
+}
+
+# check if we can find a gbp command on the commandline
+_gbp_find_cmd_on_cmdline ()
+{
+ local cmds="$1" # list of commands to check for
+ local word cmd c=1
+
+ while [ $c -lt $((COMP_CWORD)) ]; do
+ word="${COMP_WORDS[c]}"
+ for cmd in $cmds; do
+ if [ "$cmd" = "$word" ]; then
+ echo "$cmd"
+ return
+ fi
+ done
+ ((c++))
+ done
+}
+
+_gbp-buildpackage()
+{
+ local options=$(_gbp_options buildpackage)
+ local branch_opts="--git-debian-branch\= --git-upstream-branch\= --git-upstream-tree\="
+ local tag_opts="--git-debian-tag\= --git-upstream-tag\="
+ local tristate_opts="--git-color\= --git-notify\="
+
+ _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts" \
+ "$cbdist_opts"
+}
+
+
+_gbp-pq ()
+{
+ local options=$(_gbp_options pq)
+ options="$options export import rebase drop apply switch"
+ _gbp_comp "$options"
+}
+
+
+_gbp-create-remote-repo ()
+{
+ local options=$(_gbp_options create-remote-repo)
+ options="$options list"
+ _gbp_comp "$options"
+}
+
+
+_gbp-generic-cmd()
+{
+ local options=$(_gbp_options "${1}")
+ _gbp_comp "$options"
+}
+
+
+_have gbp &&
+_gbp ()
+{
+ local cur="${COMP_WORDS[COMP_CWORD]}"
+ local commands=$(_gbp_commands)
+ local func
+
+ command=$(_gbp_find_cmd_on_cmdline "$commands")
+ if [ -z "${command}" ]; then
+ COMPREPLY=( $(compgen -W "$commands" -- "${cur}" ) )
+ else
+ if type _gbp-"${command}" >& /dev/null; then
+ _gbp-"${command}"
+ else
+ _gbp-generic-cmd "${command}"
+ fi
+ fi
+} && complete -F _gbp -o default gbp
--- /dev/null
+[DEFAULT]
+debian-branch = master
+
+[dch]
+id-length = 7
+postedit = sed -i s"!^Version:.*!Version: $GBP_DEBIAN_VERSION!" packaging/git-buildpackage.spec
+++ /dev/null
-usr/lib/python*/dist-packages/gbp/bb/
-usr/lib/python*/dist-packages/gbp/scripts/*bb*.py*
+++ /dev/null
-Document: git-buildpackage
-Title: Git-Buildpackage Manual
-Author: Guido Guenther
-Abstract: git-buildpackage is a suite to help with Debian packages in Git
- repositories. This manual describes the utilities in this package, their
- configuration and possible workflows.
-Section: Programming
-
-Format: HTML
-Index: /usr/share/doc/git-buildpackage-common/manual-html/index.html
-Files: /usr/share/doc/git-buildpackage-common/manual-html/*.html
+++ /dev/null
-README
-docs/manual-html/
+++ /dev/null
-examples/*
+++ /dev/null
-usr/bin/gbp
-usr/bin/gbp-clone
-usr/bin/gbp-pull
-usr/lib/python*/dist-packages/gbp/*.py*
-usr/lib/python*/dist-packages/gbp/scripts/__init__.py*
-usr/lib/python*/dist-packages/gbp/scripts/clone.py*
-usr/lib/python*/dist-packages/gbp/scripts/config.py*
-usr/lib/python*/dist-packages/gbp/scripts/pull.py*
-usr/lib/python*/dist-packages/gbp/scripts/supercommand.py*
-usr/lib/python*/dist-packages/gbp/scripts/common/*.py*
-usr/lib/python*/dist-packages/gbp/git/*.py*
-usr/lib/python*/dist-packages/gbp/pkg/*.py*
-etc/git-buildpackage/gbp.conf
+++ /dev/null
-/usr/share/doc/git-buildpackage-common/manual-html/gbp.html /usr/share/doc/git-buildpackage-common/manual-html/index.html
+++ /dev/null
-docs/gbp.1
-docs/gbp-clone.1
-docs/gbp-config.1
-docs/gbp-pull.1
-docs/*.5
-usr/bin/*rpm*
-usr/lib/python*/dist-packages/gbp/rpm/*.py*
-usr/lib/python*/dist-packages/gbp/scripts/*rpm*.py*
+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/
--- /dev/null
+docs/gbp-import-srpm.1
+docs/gbp-pq-rpm.1
+docs/gbp-buildpackage-rpm.1
+docs/gbp-rpm-ch.1
-# -*- shell-script -*-
-#
-# Bash tab auto-completion rules for git-buildpackage.
-#
-# Copyright (C) 2010 Siegfried-Angel Gevatter Pujals <siegfried@gevatter.com>
-# Copyright (C) 2010,2013 Guido Guenther <agx@sigxcpu.org>
-#
-# Distributed under the GNU General Public License, version 2.0.
-
-_gbp_branches ()
-{
- [ -d .git ] || return 0
- git for-each-ref --format="%(refname:short)" refs/heads
-}
-
-
-_gbp_tags ()
-{
- [ -d .git ] || return 0
- git for-each-ref --format="%(refname:short)" refs/tags
-}
-
-
-_gbp_options ()
-{
- $1 --help | sed -ne 's/^ \+\(\(\-[a-z]\), \)\?\(\-\-[a-z\-]\+\=\?\).*/\2 \3/p'
-}
-
-
-_gbp_commands ()
-{
- gbp --list-cmds | sed -ne 's/^ \+\([a-z\-]\+\) \-.*/\1/p'
-}
-
-
-_gbp_comp ()
-{
- local cur="${COMP_WORDS[COMP_CWORD]}"
- local prev="${COMP_WORDS[COMP_CWORD - 1]}"
- local options=$1
- local branch_opts=$2
- local tag_opts=$3
- local tristate_opts=$4
-
-# COMPREPLY considers '=' as a word. For $prev we prefer the word before the actual "="
- if [[ "$prev" == "=" ]]; then
- prev="${COMP_WORDS[COMP_CWORD - 2]}"
- elif [[ "$cur" == "=" ]]; then
- cur=""
- fi
-
- if [[ "${branch_opts}" == *$prev* ]]; then
- local refs=$(_gbp_branches)
- COMPREPLY=( $(compgen -W "$refs" -- $cur ) )
- return 0
- fi
-
- if [[ "${tag_opts}" == *$prev* ]]; then
- local refs=$(_gbp_tags)
- COMPREPLY=( $(compgen -W "$refs" -- $cur ) )
- return 0
- fi
-
- if [[ "${tristate_opts}" == *$prev* ]]; then
- COMPREPLY=( $(compgen -W 'on off auto' -- $cur ) )
- return 0
- fi
-
- if [[ "${cbdist_opts}" == *$prev* ]]; then
- local BASE="/var/cache/pbuilder/base-"
- COMPREPLY=( $( compgen -o dirnames -G "${BASE}${cur}*.cow" \
- | sed -e "s,${BASE}\(.*\)\.cow,\1,g" ) )
- return 0
- fi
-
- # separate opts by tab so we can append a space to all options not ending
- # with an equal sign
- tab_opts=$(echo "$options" | sed -e 's/ \+/\t/g' -e 's/[^=]$/& /g')
- type compopt &>/dev/null && compopt -o nospace
- local IFS=$'\t\n'
- COMPREPLY=($(compgen -W "$tab_opts" -- $cur))
-}
-
-# check if we can find a gbp command on the commandline
-_gbp_find_cmd_on_cmdline ()
-{
- local cmds="$1" # list of commands to check for
- local word cmd c=1
-
- while [ $c -lt $((COMP_CWORD)) ]; do
- word="${COMP_WORDS[c]}"
- for cmd in $cmds; do
- if [ "$cmd" = "$word" ]; then
- echo "$cmd"
- return
- fi
- done
- ((c++))
- done
-}
-
-have git-buildpackage &&
-_gbp_buildpackage()
-{
- local options=$(_gbp_options git-buildpackage)
- local branch_opts="--git-debian-branch\= --git-upstream-branch\= --git-upstream-tree\="
- local tag_opts="--git-debian-tag\= --git-upstream-tag\="
- local tristate_opts="--git-color\= --git-notify\="
- local cbdist_opts="--git-dist\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts" \
- "$cbdist_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_buildpackage -o default git-buildpackage
-
-
-have git-dch &&
-_gbp_dch ()
-{
- local options=$(_gbp_options git-dch)
- local branch_opts="--debian-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_dch -o default git-dch
-
-
-have git-import-orig &&
-_gbp_import_orig ()
-{
- local options=$(_gbp_options git-import-orig)
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_import_orig -o default git-import-orig
-
-
-have git-import-dsc &&
-_gbp_import_dsc ()
-{
- local options=$(_gbp_options git-import-dsc)
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_import_dsc -o default git-import-dsc
-
-have git-import-dscs &&
-_gbp_import_dscs ()
-{
- local options="$(_gbp_options git-import-dscs) $(_gbp_options git-import-dsc)"
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_import_dscs -o default git-import-dscs
-
-have gbp-pq &&
-_gbp_pq ()
-{
- local options=$(_gbp_options gbp-pq)
- options="$options export import rebase drop apply switch"
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "" "" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_pq -o default gbp-pq
-
-have gbp-pull &&
-_gbp_pull ()
-{
- local options=$(_gbp_options gbp-pull)
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_pull -o default gbp-pull
-
-have gbp-clone &&
-_gbp_clone ()
-{
- local options=$(_gbp_options gbp-clone)
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tag_opts="--debian-tag\= --upstream-tag\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "$tag_opts" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_clone -o default gbp-clone
-
-have gbp-create-remote-repo &&
-_gbp_create_remote_repo ()
-{
- local options=$(_gbp_options gbp-create-remote-repo)
- local branch_opts="--debian-branch\= --upstream-branch\="
- local tristate_opts="--color\="
-
- _gbp_comp "$options" "$branch_opts" "" "$tristate_opts"
-}
-[ "${have:-}" ] && complete -F _gbp_create_remote_repo -o default gbp-create-remote-repo
-
-have gbp &&
-_gbp ()
-{
- local cur="${COMP_WORDS[COMP_CWORD]}"
- local commands=$(_gbp_commands)
- local func
-
- command=$(_gbp_find_cmd_on_cmdline "$commands")
- if [ -z $command ]; then
- COMPREPLY=( $(compgen -W "$commands" -- $cur ) )
- else
- func=_gbp_$(echo $command | sed -e 's/-/_/g')
- $func
- fi
-}
-[ "${have:-}" ] && complete -F _gbp -o default gbp
+debian/gbp.completion gbp
--- /dev/null
+Document: git-buildpackage
+Title: Git-Buildpackage Manual
+Author: Guido Günther
+Abstract: git-buildpackage is a suite to help with Debian packages in Git
+ repositories. This manual describes the utilities in this package, their
+ configuration and possible workflows.
+Section: Programming
+
+Format: HTML
+Index: /usr/share/doc/git-buildpackage/manual-html/index.html
+Files: /usr/share/doc/git-buildpackage/manual-html/*.html
--- /dev/null
+README.md
+docs/manual-html/
+build/apidocs/
--- /dev/null
+examples/*
-usr/bin/gbp-pq
-usr/bin/git-buildpackage
-usr/bin/git-dch
-usr/bin/git-import-dsc
-usr/bin/git-import-dscs
-usr/bin/git-import-orig
+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/bin/gbp-create-remote-repo
-usr/lib/python*/dist-packages/gbp/deb/*.py*
-usr/lib/python*/dist-packages/gbp/scripts/pq.py*
-usr/lib/python*/dist-packages/gbp/scripts/buildpackage.py*
-usr/lib/python*/dist-packages/gbp/scripts/dch.py*
-usr/lib/python*/dist-packages/gbp/scripts/import_dsc.py*
-usr/lib/python*/dist-packages/gbp/scripts/import_dscs.py*
-usr/lib/python*/dist-packages/gbp/scripts/import_orig.py*
-usr/lib/python*/dist-packages/gbp/scripts/create_remote_repo.py*
+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/
--- /dev/null
+/usr/share/man/man1/gbp.1.gz /usr/share/man/man1/git-buildpackage.1.gz
+/usr/lib/python3/dist-packages/gbp/scripts/supercommand.py /usr/bin/gbp
+docs/gbp.1
docs/gbp-buildpackage.1
+docs/gbp-clone.1
+docs/gbp.conf.5
+docs/gbp-config.1
docs/gbp-create-remote-repo.1
docs/gbp-dch.1
+docs/gbp-export-orig.1
docs/gbp-import-dsc.1
docs/gbp-import-dscs.1
docs/gbp-import-orig.1
+docs/gbp-import-ref.1
docs/gbp-pq.1
+docs/gbp-pristine-tar.1
+docs/gbp-pull.1
+docs/gbp-push.1
+docs/gbp-setup-gitattributes.1
+docs/gbp-tag.1
docs/git-pbuilder.1
+++ /dev/null
-#compdef gbp
-#description build debian packages from a git repository
-
-__gbp_common_options() {
- local prefix="$1"
- # these can't be prefixed
- _arguments '--help[Show help]' \
- '--version[Show version information]'
-
- _arguments "--${prefix}verbose[Verbose execution]" \
- "--${prefix}color=-[Use colored output]:color:(on auto off)"
-
-}
-
-__gbp_branch_options() {
- local prefix="$1"
- _arguments \
- "--${prefix}debian-branch=-[The branch the Debian package is being developed on]" \
- "--${prefix}upstream-branch=-[The branch the upstream sources are put onto]" \
- "--${prefix}pristine-tar[Track pristine tar branch]"
-}
-
-__gbp_tag_format_options() {
- local prefix="$1"
- _arguments \
- "--${prefix}debian-tag=-[format string for debian tags]" \
- "--${prefix}upstream-tag=-[format string for upstream tags]"
-}
-
-__gbp_tag_sign_options() {
- local prefix="$1"
- _arguments \
- "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}sign-tags[GPG sign all generated tags]" \
- "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}no-sign-tags[Do not GPG sign generated tags]" \
- "--${prefix}keyid=-[GPG keyid to sign tags with]:GPG key:"
-}
-
-_gbp() {
- local curcontext="$curcontext" state line
- typeset -A opt_args
- _arguments -C \
- ':command:->command' \
- '*::options:->options' \
-
- case $state in
- (command)
- #breaks if defined outside the func
- local -a subcommands
- subcommands=(
- 'buildpackage:Build a Debian package'
- 'clone:Clone a Git repository from a remote and set up the necessary branch tracking.'
- 'create-remote-repo:Create a remote Git repository'
- 'dch:Generate the debian/changelog from Git commit history'
- 'import-dsc:Import a single Debian source package'
- 'import-dscs:Import multiple Debian source packages'
- 'import-orig:Import a new upstream tarball'
- 'pq:Manage debian/patches using Git rebase'
- 'pull:Update a Git repository from a remote'
- )
-
- _describe -t commands gbp subcommands
- ;;
- (options)
- local funcname
- funcname=_gbp-$line[1]
- if type $funcname | grep -q "shell function" ; then
- $funcname
- fi
- ;;
- esac
-}
-
-_gbp-buildpackage() {
- __gbp_common_options git-
- __gbp_branch_options git-
- __gbp_tag_format_options git-
- __gbp_tag_sign_options git-
- _arguments \
- '--git-ignore-new[build with uncommited changes in the source tree]' \
- '--git-no-ignore-new[negates --git-ignore-new]' \
- '--git-tag[create a tag after a successful build]' \
- '--git-tag-only[do not build, only tag and run the posttag hook]' \
- '--git-retag[do not fail if the tag already exists]' \
- '--git-force-create[force creation of orig.tar.gz]' \
- '--git-no-create-orig[do not create orig.tar.gz]' \
- '--git-tarball-dir=-[location to look for external tarballs]:tarball directory:_files -/' \
- '--git-compression=-[compression type]:compression:(auto gzip bzip2 lzma xz)' \
- '--git-compression-level=-[set compression level]:level:(1 2 3 4 5 6 7 8 9)' \
- '--git-ignore-branch[build although debian-branch != current branch]' \
- '--git-no-ignore-branch[negates --git-ignore-branch]' \
- '--git-builder=-[command to build the Debian package]:command:' \
- '--git-cleaner=-[command to clean the working copy]:command:' \
- '--git-prebuild=-[command to run before a build]:command:' \
- '--git-postbuild=-[hook run after a successful build]:command:' \
- '--git-posttag=-[hook run after a successful tag operation]:command:' \
- '--git-pbuilder[invoke git-pbuilder for building]' \
- '--git-no-pbuilder[negates --git-pbuilder]' \
- '--git-dist=-[build for this distribution when using git-pbuilder]:distribution:' \
- '--git-arch=-[build for this architecture when using git-pbuilder]:architecture:' \
- '--git-export-dir=-[before building the package export the source into this directory]:directory:_files -/' \
- '--git-export=-[export treeish object instead of HEAD]:treeish:' \
- '--git-dont-purge[retain exported package build directory]' \
- '--git-overlay[extract orig tarball when using export-dir option]' \
- '--git-no-overlay[negates --git-overlay]' \
- '--git-notify=-[Send a desktop notification after build]:notify:(on auto off)' \
- '*:Other options:_dpkg-buildpackage'
-}
-
-_gbp-clone() {
- __gbp_common_options
- __gbp_branch_options
- _arguments \
- '--all[Track all branches, not only debian and upstream]'
-}
-
-_gbp-create-remote-repo() {
- __gbp_common_options
- _arguments \
- '--remote-url-pattern=-[Where to create remote repository]' \
- '--remote-name=-[What name git will use when refering to that repository]' \
- '--template-dir=-[Template dir to pass to git init]' \
- '--remote-config=-[Name of config file section to specify params]' \
- '(--track --no-track)--track[Set up branch tracking]' \
- '(--track --no-track)--no-track[Do not set up branch tracking]'
-
-}
-
-_gbp-dch () {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
-
- _arguments \
- '--git-ignore-branch[build although debian-branch != current branch]' \
- '--since=-[Start point for reading commits]:commitish:' \
- '--auto[Guess the last commit documented in the changelog]' \
- '(--meta --no-meta)--meta[Parse meta tags]' \
- '(--meta --no-meta)--no-meta[Do not parse meta tags]' \
- '--meta-closes=-[What meta tags to look for to generate bug-closing changelog entries]' \
- '(--full --no-full)--full[Include the full commit message]' \
- '(--full --no-full)--no-full[Do not include the full commit message]' \
- '(--snapshot -S)'{-S,--snapshot}'[Create a snapshot release entry]' \
- '--snapshot-number=-[Python expression that gets eval()ed to the new snapshot number]' \
- '(--release -R)'{-R,--release}'[Remove any snapshot release banners]' \
- '(--new-version -N)'{-R,--release}'=[Specify changelog version]' \
- '--team[Create a team upload entry]' \
- '--bpo[Increment the release number for a backports upload]' \
- '--nmu[Increment the release number for a NMU upload]' \
- '--qa[Increment the release number for a QA upload]' \
- '--distribution=-[Set the distribution field]' \
- '--force-distribution[Force distribution]' \
- '--urgency=-[Set the upload urgency]' \
- '--git-log=-[Options passed to git log]' \
- '--id-length=-[Number of commit id digits to include]' \
- '--ignore-regex=-[Ignore matching commit lines]' \
- '--git-author[Use git name configuration for changelog signature]' \
- '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Merge commits by maintainer]' \
- '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Do not merge commits by maintainer]' \
- '--spawn-editor=[Spawn an editor]:when:(always snapshot release)' \
- '--commit-msg=[Commit message format string]' \
- '--commit[Commit the generated changelog]' \
- '*:Paths:_files -/'
-}
-
-_gbp-import-dsc() {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
- __gbp_tag_sign_options
- _arguments \
- '--filter=-[Filter out files]' \
- '--download=-[Download the source package]' \
- '--allow-unauthenticated[Skip signature verification on downloads]' \
- '--allow-same-version[Import a package with the same debian version]' \
- '--author-is-committer[Use the author identity as committer identity]' \
- '--author-date-is-committer-date[Use author date as commit date]' \
- '*:package:_files -g "*.dsc"'
- # TODO: complete source package names
- # TODO: pass only one tarball/source package name
-}
-
-_gbp-import-dscs() {
- # same options
- _gbp-import_dsc
- _arguments \
- '--debsnap[Fetch snapshots from snapshots.debian.org]' \
- '--ignore-repo-config[Ignore options in gbp.conf]'
- # TODO: multiple dscs or one source package name + debsnap
-}
-
-_gbp-import-orig() {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
- __gbp_tag_sign_options
- _arguments \
- '(--upstream-version -u)'{--upstream-version,-u}'=[The upstream version number]' \
- '--merge[Merge the upstream branch into the debian branch]' \
- '--upstream-vcs-tag=-[Add a tag as an additional parent to the upstream tarball commit]' \
- '--import-msg=-[Commit message format string]' \
- '--filter=-[Filter out files]' \
- '--filter-pristine-tar[When filtering also filter out of pristine-tar tarballs]' \
- '(--symlink-orig --no-symlink-orig)--symlink-orig=[Create a symlink with a debian-compliant name]' \
- '(--symlink-orig --no-symlink-orig)--no-symlink-orig=[Do not create a symlink with a debian-compliant name]' \
- '--postimport=-[Run a command after import]' \
- '--uscan[Use uscan to fetch the new upstream version]' \
- '*:file:_files'
-
- # TODO: pass only one tarball
- # TODO: Do not complete files when uscan option is enabled
-}
-
-_gbp-pq() {
- __gbp_common_options
- _arguments \
- '(--patch-numbers --no-patch-numbers)--patch-numbers[Add numbers to patch files]' \
- '(--patch-numbers --no-patch-numbers)--no-patch-numbers[Do not add numbers to patch files]' \
- '--topic=-[Topic to use when importing a single patch]' \
- '--time-machine=-[Go back N commits trying to apply patch queue]'
-
- local -a pqcommands
- pqcommands=(
- 'import:Create a patch queue branch'
- 'export:Export the patches on the patch-queue branch'
- 'rebase:Rebase the patch-queue branch against the current branch'
- 'drop:Drop the patch queue'
- 'apply:Add a single patch to the patch-queue'
- 'switch:Switch to the patch-queue branch if on the base branch and viceversa'
- )
- # TODO: only display these commands once
- _describe -t pqcommands gbp-pq pqcommands
-}
-
-_gbp-pull() {
- __gbp_common_options
- __gbp_branch_options
- _arguments \
- '--force[Update even non fast-forward]' \
- '--redo-pq[Rebuild the patch queue]' \
- '--ignore-branch[Dont care if on a detached state]' \
- '--depth=-[Depth for deepening shallow clones]'
-}
-
-_gbp "$@"
-
-
-
-__gbp_common_options() {
- local prefix="$1"
- # these can't be prefixed
- _arguments '--help[Show help]' \
- '--version[Show version information]'
-
- _arguments "--${prefix}verbose[Verbose execution]" \
- "--${prefix}color=-[Use colored output]:color:(on auto off)"
-
-}
-
-__gbp_branch_options() {
- local prefix="$1"
- _arguments \
- "--${prefix}debian-branch=-[The branch the Debian package is being developed on]" \
- "--${prefix}upstream-branch=-[The branch the upstream sources are put onto]" \
- "--${prefix}pristine-tar[Track pristine tar branch]"
-}
-
-__gbp_tag_format_options() {
- local prefix="$1"
- _arguments \
- "--${prefix}debian-tag=-[format string for debian tags]" \
- "--${prefix}upstream-tag=-[format string for upstream tags]"
-}
-
-__gbp_tag_sign_options() {
- local prefix="$1"
- _arguments \
- "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}sign-tags[GPG sign all generated tags]" \
- "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}no-sign-tags[Do not GPG sign generated tags]" \
- "--${prefix}keyid=-[GPG keyid to sign tags with]:GPG key:"
-}
-
-_gbp() {
- local curcontext="$curcontext" state line
- typeset -A opt_args
- _arguments -C \
- ':command:->command' \
- '*::options:->options' \
-
- case $state in
- (command)
- #breaks if defined outside the func
- local -a subcommands
- subcommands=(
- 'buildpackage:Build a Debian package'
- 'clone:Clone a Git repository from a remote and set up the necessary branch tracking.'
- 'create-remote-repo:Create a remote Git repository'
- 'dch:Generate the debian/changelog from Git commit history'
- 'import-dsc:Import a single Debian source package'
- 'import-dscs:Import multiple Debian source packages'
- 'import-orig:Import a new upstream tarball'
- 'pq:Manage debian/patches using Git rebase'
- 'pull:Update a Git repository from a remote'
- )
-
- _describe -t commands gbp subcommands
- ;;
- (options)
- local funcname
- funcname=_gbp-$line[1]
- if type $funcname | grep -q "shell function" ; then
- $funcname
- fi
- ;;
- esac
-}
-
-_gbp-buildpackage() {
- __gbp_common_options git-
- __gbp_branch_options git-
- __gbp_tag_format_options git-
- __gbp_tag_sign_options git-
- _arguments \
- '--git-ignore-new[build with uncommited changes in the source tree]' \
- '--git-no-ignore-new[negates --git-ignore-new]' \
- '--git-tag[create a tag after a successful build]' \
- '--git-tag-only[do not build, only tag and run the posttag hook]' \
- '--git-retag[do not fail if the tag already exists]' \
- '--git-force-create[force creation of orig.tar.gz]' \
- '--git-no-create-orig[do not create orig.tar.gz]' \
- '--git-tarball-dir=-[location to look for external tarballs]:tarball directory:_files -/' \
- '--git-compression=-[compression type]:compression:(auto gzip bzip2 lzma xz)' \
- '--git-compression-level=-[set compression level]:level:(1 2 3 4 5 6 7 8 9)' \
- '--git-ignore-branch[build although debian-branch != current branch]' \
- '--git-no-ignore-branch[negates --git-ignore-branch]' \
- '--git-builder=-[command to build the Debian package]:command:' \
- '--git-cleaner=-[command to clean the working copy]:command:' \
- '--git-prebuild=-[command to run before a build]:command:' \
- '--git-postbuild=-[hook run after a successful build]:command:' \
- '--git-posttag=-[hook run after a successful tag operation]:command:' \
- '--git-pbuilder[invoke git-pbuilder for building]' \
- '--git-no-pbuilder[negates --git-pbuilder]' \
- '--git-dist=-[build for this distribution when using git-pbuilder]:distribution:' \
- '--git-arch=-[build for this architecture when using git-pbuilder]:architecture:' \
- '--git-export-dir=-[before building the package export the source into this directory]:directory:_files -/' \
- '--git-export=-[export treeish object instead of HEAD]:treeish:' \
- '--git-dont-purge[retain exported package build directory]' \
- '--git-overlay[extract orig tarball when using export-dir option]' \
- '--git-no-overlay[negates --git-overlay]' \
- '--git-notify=-[Send a desktop notification after build]:notify:(on auto off)' \
- '*:Other options:_dpkg-buildpackage'
-}
-
-_gbp-clone() {
- __gbp_common_options
- __gbp_branch_options
- _arguments \
- '--all[Track all branches, not only debian and upstream]'
-}
-
-_gbp-create-remote-repo() {
- __gbp_common_options
- _arguments \
- '--remote-url-pattern=-[Where to create remote repository]' \
- '--remote-name=-[What name git will use when refering to that repository]' \
- '--template-dir=-[Template dir to pass to git init]' \
- '--remote-config=-[Name of config file section to specify params]' \
- '(--track --no-track)--track[Set up branch tracking]' \
- '(--track --no-track)--no-track[Do not set up branch tracking]'
-
-}
-
-_gbp-dch () {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
-
- _arguments \
- '--git-ignore-branch[build although debian-branch != current branch]' \
- '--since=-[Start point for reading commits]:commitish:' \
- '--auto[Guess the last commit documented in the changelog]' \
- '(--meta --no-meta)--meta[Parse meta tags]' \
- '(--meta --no-meta)--no-meta[Do not parse meta tags]' \
- '--meta-closes=-[What meta tags to look for to generate bug-closing changelog entries]' \
- '(--full --no-full)--full[Include the full commit message]' \
- '(--full --no-full)--no-full[Do not include the full commit message]' \
- '(--snapshot -S)'{-S,--snapshot}'[Create a snapshot release entry]' \
- '--snapshot-number=-[Python expression that gets eval()ed to the new snapshot number]' \
- '(--release -R)'{-R,--release}'[Remove any snapshot release banners]' \
- '(--new-version -N)'{-R,--release}'=[Specify changelog version]' \
- '--team[Create a team upload entry]' \
- '--bpo[Increment the release number for a backports upload]' \
- '--nmu[Increment the release number for a NMU upload]' \
- '--qa[Increment the release number for a QA upload]' \
- '--distribution=-[Set the distribution field]' \
- '--force-distribution[Force distribution]' \
- '--urgency=-[Set the upload urgency]' \
- '--git-log=-[Options passed to git log]' \
- '--id-length=-[Number of commit id digits to include]' \
- '--ignore-regex=-[Ignore matching commit lines]' \
- '--git-author[Use git name configuration for changelog signature]' \
- '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Merge commits by maintainer]' \
- '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Do not merge commits by maintainer]' \
- '--spawn-editor=[Spawn an editor]:when:(always snapshot release)' \
- '--commit-msg=[Commit message format string]' \
- '--commit[Commit the generated changelog]' \
- '*:Paths:_files -/'
-}
-
-_gbp-import-dsc() {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
- __gbp_tag_sign_options
- _arguments \
- '--filter=-[Filter out files]' \
- '--download=-[Download the source package]' \
- '--allow-unauthenticated[Skip signature verification on downloads]' \
- '--allow-same-version[Import a package with the same debian version]' \
- '--author-is-committer[Use the author identity as committer identity]' \
- '--author-date-is-committer-date[Use author date as commit date]' \
- '*:package:_files -g "*.dsc"'
- # TODO: complete source package names
- # TODO: pass only one tarball/source package name
-}
-
-_gbp-import-dscs() {
- # same options
- _gbp-import_dsc
- _arguments \
- '--debsnap[Fetch snapshots from snapshots.debian.org]' \
- '--ignore-repo-config[Ignore options in gbp.conf]'
- # TODO: multiple dscs or one source package name + debsnap
-}
-
-_gbp-import-orig() {
- __gbp_common_options
- __gbp_branch_options
- __gbp_tag_format_options
- __gbp_tag_sign_options
- _arguments \
- '(--upstream-version -u)'{--upstream-version,-u}'=[The upstream version number]' \
- '--merge[Merge the upstream branch into the debian branch]' \
- '--upstream-vcs-tag=-[Add a tag as an additional parent to the upstream tarball commit]' \
- '--import-msg=-[Commit message format string]' \
- '--filter=-[Filter out files]' \
- '--filter-pristine-tar[When filtering also filter out of pristine-tar tarballs]' \
- '(--symlink-orig --no-symlink-orig)--symlink-orig=[Create a symlink with a debian-compliant name]' \
- '(--symlink-orig --no-symlink-orig)--no-symlink-orig=[Do not create a symlink with a debian-compliant name]' \
- '--postimport=-[Run a command after import]' \
- '--uscan[Use uscan to fetch the new upstream version]' \
- '*:file:_files'
-
- # TODO: pass only one tarball
- # TODO: Do not complete files when uscan option is enabled
-}
-
-_gbp-pq() {
- __gbp_common_options
- _arguments \
- '(--patch-numbers --no-patch-numbers)--patch-numbers[Add numbers to patch files]' \
- '(--patch-numbers --no-patch-numbers)--no-patch-numbers[Do not add numbers to patch files]' \
- '--topic=-[Topic to use when importing a single patch]' \
- '--time-machine=-[Go back N commits trying to apply patch queue]'
-
- local -a pqcommands
- pqcommands=(
- 'import:Create a patch queue branch'
- 'export:Export the patches on the patch-queue branch'
- 'rebase:Rebase the patch-queue branch against the current branch'
- 'drop:Drop the patch queue'
- 'apply:Add a single patch to the patch-queue'
- 'switch:Switch to the patch-queue branch if on the base branch and viceversa'
- )
- # TODO: only display these commands once
- _describe -t pqcommands gbp-pq pqcommands
-}
-
-_gbp-pull() {
- __gbp_common_options
- __gbp_branch_options
- _arguments \
- '--force[Update even non fast-forward]' \
- '--redo-pq[Rebuild the patch queue]' \
- '--ignore-branch[Dont care if on a detached state]' \
- '--depth=-[Depth for deepening shallow clones]'
-}
-
-_gbp "$@"
+++ /dev/null
-/usr/share/doc/git-buildpackage/manual-html/gbp.html /usr/share/doc/git-buildpackage/manual-html/index.html
-# As long as we keep the old aliases
-/usr/share/man/man1/gbp-import-orig.1.gz /usr/share/man/man1/git-import-orig.1.gz
-/usr/share/man/man1/gbp-buildpackage.1.gz /usr/share/man/man1/git-buildpackage.1.gz
-/usr/share/man/man1/gbp-import-dsc.1.gz /usr/share/man/man1/git-import-dsc.1.gz
-/usr/share/man/man1/gbp-import-dscs.1.gz /usr/share/man/man1/git-import-dscs.1.gz
-/usr/share/man/man1/gbp-dch.1.gz /usr/share/man/man1/git-dch.1.gz
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__
+
--- /dev/null
+#!/bin/sh
+set -e
+
+gbp import-dsc --debian-branch=pk4 --upstream-branch=upstream "$1" "$2"
+# Add local gbp.conf to override any branch settings in 'debian/gbp.conf'
+# (since this checkout wasn't created by "gbp clone"). We want to be sure the
+# branches exist so we can build the package right away.
+cat <<EOF > "$2"/.git/gbp.conf
+[DEFAULT]
+upstream-branch = upstream
+debian-branch = pk4
+EOF
#!/usr/bin/make -f
-# HACK: disable checks, i.e. unit tests
-DEB_BUILD_OPTIONS += nocheck
-export WITHOUT_NOSETESTS := 1
-
-EXAMPLE_SCRIPTS=\
- gbp-add-patch \
- gbp-cowbuilder-sid \
- gbp-posttag-push \
- gbp-configure-unpatched-source \
- wrap_cl.py
-
-DEB_COMPRESS_EXCLUDE=$(EXAMPLE_SCRIPTS)
-
-ZSH_COMPDIR = /usr/share/zsh/vendor-completions/
-
-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)))
- dh_auto_test
- export GIT_AUTHOR_NAME="Gbp Tests"; \
- export GIT_AUTHOR_EMAIL=tests@example.com; \
- export GIT_COMMITTER_NAME=$$GIT_AUTHOR_NAME; \
- export GIT_COMMITTER_EMAIL=$$GIT_AUTHOR_EMAIL; \
- PYTHONPATH=. \
- python3 setup.py nosetests
-
-else
- @echo "Checks disabled via DEB_BUILD_OPTIONS"
-endif
+ make
-override_dh_auto_build:
- dh_auto_build
- make -C docs
+execute_after_dh_auto_build:
+ make docs
-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
+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
- # Remove renamed files - renames are not correctly expressed in debian.diff
- rm -f debian/doc-base
- rm -f debian/docs
- rm -f debian/examples
- rm -f debian/manpages
- rm -rf build/
+execute_after_dh_auto_clean:
make -C docs/ clean
- -rm gbp/version.py
-
-override_dh_compress:
- dh_compress --exclude=usr/share/doc/git-buildpackage/examples/
-
+ find gbp -name __init__.py -printf '%h/__pycache__/\n' | xargs rm -fr
--- /dev/null
+---
+include:
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/salsa-ci.yml
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/pipeline-jobs.yml
+
+# Reprotest triggers a test failure not related to reproducibility
+variables:
+ SALSA_CI_DISABLE_REPROTEST: 1
+
+++ /dev/null
-extend-diff-ignore = "^(tests/test_rpm_data/.*|tests/component/rpm/data/.*|tests/component/deb/data/.*)"
-diff-ignore
--- /dev/null
+Tests: smoke-rpm
+Depends: @, @builddeps@
+Restrictions: allow-stderr
--- /dev/null
+#!/bin/sh
+
+set -e
+set -x
+
+cleanup()
+{
+ [ -z "${GBP_TEMPDIR}" ] || rm -rf "${GBP_TEMPDIR}"
+}
+
+trap cleanup EXIT
+
+git init .
+git config user.email "you@example.com"
+git config user.name "Doesnot Matter"
+git add .
+git commit -m"Smoketest" -a
+
+gbp buildpackage-rpm --help
+
+# Build an RPM of ourselfes if build-deps are available
+if python3 -c "import setuptools"; then
+ GBP_TEMPDIR=$(mktemp -d)
+ gbp buildpackage-rpm --git-packaging-dir=packaging/ \
+ --git-export-dir="$GBP_TEMPDIR" \
+ -D'%__python3 /usr/bin/python3' \
+ -D'%__python /usr/bin/python3' \
+ -D'%python_sitelib %(%{__python3} -Ic "from sysconfig import get_path; print(get_path('"'platlib'"', '"'posix_prefix'"'))")' \
+ -D'%_arch noarch' \
+ -bb --nodeps
+fi
--- /dev/null
+#compdef gbp
+#description build Debian packages from a Git repository
+
+__gbp_common_options() {
+ local prefix="$1"
+ # these can't be prefixed
+ _arguments '--help[Show help]' \
+ '--version[Show version information]'
+
+ _arguments "--${prefix}verbose[Verbose execution]" \
+ "--${prefix}color=-[Use colored output]:color:(on auto off)"
+
+}
+
+__gbp_branch_options() {
+ local prefix="$1"
+ _arguments \
+ "--${prefix}debian-branch=-[The branch the Debian package is being developed on]" \
+ "--${prefix}upstream-branch=-[The branch the upstream sources are put onto]" \
+ "--${prefix}pristine-tar[Track pristine tar branch]"
+}
+
+__gbp_tag_format_options() {
+ local prefix="$1"
+ _arguments \
+ "--${prefix}debian-tag=-[format string for debian tags]" \
+ "--${prefix}upstream-tag=-[format string for upstream tags]"
+}
+
+__gbp_tag_sign_options() {
+ local prefix="$1"
+ _arguments \
+ "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}sign-tags[GPG sign all generated tags]" \
+ "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}no-sign-tags[Do not GPG sign generated tags]" \
+ "--${prefix}keyid=-[GPG keyid to sign tags with]:GPG key:"
+}
+
+_gbp() {
+ local curcontext="$curcontext" state line
+ typeset -A opt_args
+ _arguments -C \
+ ':command:->command' \
+ '*::options:->options' \
+
+ case $state in
+ (command)
+ #breaks if defined outside the func
+ local -a subcommands
+ subcommands=(
+ 'buildpackage:Build a Debian package'
+ 'clone:Clone a Git repository from a remote and set up the necessary branch tracking'
+ 'config:Query configuration values'
+ 'create-remote-repo:Create a remote Git repository'
+ 'dch:Generate the debian/changelog from Git commit history'
+ 'export-orig:Create orig tarballs from git'
+ 'import-dsc:Import a single Debian source package'
+ 'import-dscs:Import multiple Debian source packages'
+ 'import-orig:Import a new upstream tarball'
+ 'import-ref:Update upstream sources when using Git only'
+ 'pq:Manage debian/patches using Git rebase'
+ 'pristine-tar:Manage pristine-tar commits in a git repository'
+ 'pull:Update a Git repository from a remote'
+ 'push:Push Debian packaging changes to a Git remote'
+ 'tag:Tag a Debian packages in a Git repository'
+ )
+
+ _describe -t commands gbp subcommands
+ ;;
+ (options)
+ local funcname
+ funcname=_gbp-$line[1]
+ if type $funcname | grep -q "shell function" ; then
+ $funcname
+ fi
+ ;;
+ esac
+}
+
+_gbp-buildpackage() {
+ __gbp_common_options git-
+ __gbp_branch_options git-
+ __gbp_tag_format_options git-
+ __gbp_tag_sign_options git-
+ _arguments \
+ '--git-ignore-new[build with uncommitted changes in the source tree]' \
+ '--git-no-ignore-new[negates --git-ignore-new]' \
+ '--git-tag[create a tag after a successful build]' \
+ '--git-tag-only[do not build, only tag and run the posttag hook]' \
+ '--git-retag[do not fail if the tag already exists]' \
+ '--git-force-create[force creation of orig.tar.gz]' \
+ '--git-no-create-orig[do not create orig.tar.gz]' \
+ '--git-tarball-dir=-[location to look for external tarballs]:tarball directory:_files -/' \
+ '--git-compression=-[compression type]:compression:(auto gzip bzip2 lzma xz)' \
+ '--git-compression-level=-[set compression level]:level:(1 2 3 4 5 6 7 8 9)' \
+ '--git-ignore-branch[build although debian-branch != current branch]' \
+ '--git-no-ignore-branch[negates --git-ignore-branch]' \
+ '--git-builder=-[command to build the Debian package]:command:' \
+ '--git-cleaner=-[command to clean the working copy]:command:' \
+ '--git-prebuild=-[command to run before a build]:command:' \
+ '--git-postbuild=-[hook run after a successful build]:command:' \
+ '--git-posttag=-[hook run after a successful tag operation]:command:' \
+ '--git-pbuilder[invoke git-pbuilder for building]' \
+ '--git-no-pbuilder[negates --git-pbuilder]' \
+ '--git-dist=-[build for this distribution when using git-pbuilder]:distribution:' \
+ '--git-arch=-[build for this architecture when using git-pbuilder]:architecture:' \
+ '--git-export-dir=-[before building the package export the source into this directory]:directory:_files -/' \
+ '--git-export=-[export treeish object instead of HEAD]:treeish:' \
+ '--git-dont-purge[retain exported package build directory]' \
+ '--git-overlay[extract orig tarball when using export-dir option]' \
+ '--git-no-overlay[negates --git-overlay]' \
+ '--git-notify=-[Send a desktop notification after build]:notify:(on auto off)' \
+ '*:Other options:_dpkg-buildpackage'
+}
+
+_gbp-clone() {
+ __gbp_common_options
+ __gbp_branch_options
+ _arguments \
+ '--all[Track all branches, not only debian and upstream]'
+}
+
+_gbp-create-remote-repo() {
+ __gbp_common_options
+ _arguments \
+ '--remote-url-pattern=-[Where to create remote repository]' \
+ '--remote-name=-[What name git will use when refering to that repository]' \
+ '--template-dir=-[Template dir to pass to git init]' \
+ '--remote-config=-[Name of config file section to specify params]' \
+ '(--track --no-track)--track[Set up branch tracking]' \
+ '(--track --no-track)--no-track[Do not set up branch tracking]'
+
+}
+
+_gbp-dch () {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+
+ _arguments \
+ '--ignore-branch[build although debian-branch != current branch]' \
+ '--since=-[Start point for reading commits]:commitish:' \
+ '--auto[Guess the last commit documented in the changelog]' \
+ '(--meta --no-meta)--meta[Parse meta tags]' \
+ '(--meta --no-meta)--no-meta[Do not parse meta tags]' \
+ '--meta-closes=-[What meta tags to look for to generate bug-closing changelog entries]' \
+ '--meta-closes-bugnum=-[What bug number format to look for to generate bug-closing changelog entries]' \
+ '(--full --no-full)--full[Include the full commit message]' \
+ '(--full --no-full)--no-full[Do not include the full commit message]' \
+ '(--snapshot -S)'{-S,--snapshot}'[Create a snapshot release entry]' \
+ '--snapshot-number=-[Python expression that gets eval()ed to the new snapshot number]' \
+ '(--release -R)'{-R,--release}'[Remove any snapshot release banners]' \
+ '(--new-version -N)'{-R,--release}'=[Specify changelog version]' \
+ '--team[Create a team upload entry]' \
+ '--bpo[Increment the release number for a backports upload]' \
+ '--nmu[Increment the release number for a NMU upload]' \
+ '--qa[Increment the release number for a QA upload]' \
+ '(--local -l)'{-l,--local}'=-[Increment the release number for a local build]' \
+ '--distribution=-[Set the distribution field]' \
+ '--force-distribution[Force distribution]' \
+ '--urgency=-[Set the upload urgency]' \
+ '--git-log=-[Options passed to git log]' \
+ '--id-length=-[Number of commit id digits to include]' \
+ '--ignore-regex=-[Ignore matching commit lines]' \
+ '--git-author[Use git name configuration for changelog signature]' \
+ '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Merge commits by maintainer]' \
+ '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Do not merge commits by maintainer]' \
+ '--spawn-editor=[Spawn an editor]:when:(always never snapshot release)' \
+ '--commit-msg=[Commit message format string]' \
+ '--commit[Commit the generated changelog]' \
+ '*:Paths:_files -/'
+}
+
+_gbp-import-dsc() {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+ __gbp_tag_sign_options
+ _arguments \
+ '--filter=-[Filter out files]' \
+ '--allow-unauthenticated[Skip signature verification on downloads]' \
+ '--allow-same-version[Import a package with the same debian version]' \
+ '--author-is-committer[Use the author identity as committer identity]' \
+ '--author-date-is-committer-date[Use author date as commit date]' \
+ '*:package:_files -g "*.dsc"'
+ # TODO: complete source package names
+ # TODO: pass only one tarball/source package name
+}
+
+_gbp-import-dscs() {
+ # same options
+ _gbp-import-dsc
+ _arguments \
+ '--debsnap[Fetch snapshots from snapshots.debian.org]' \
+ '--ignore-repo-config[Ignore options in gbp.conf]'
+ # TODO: multiple dscs or one source package name + debsnap
+}
+
+_gbp-import-orig() {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+ __gbp_tag_sign_options
+ _arguments \
+ '(--upstream-version -u)'{--upstream-version,-u}'=[The upstream version number]' \
+ '--merge[Merge the upstream branch into the debian branch]' \
+ '--upstream-vcs-tag=-[Add a tag as an additional parent to the upstream tarball commit]' \
+ '--import-msg=-[Commit message format string]' \
+ '--filter=-[Filter out files]' \
+ '--filter-pristine-tar[When filtering also filter out of pristine-tar tarballs]' \
+ '(--symlink-orig --no-symlink-orig)--symlink-orig=[Create a symlink with a debian-compliant name]' \
+ '(--symlink-orig --no-symlink-orig)--no-symlink-orig=[Do not create a symlink with a debian-compliant name]' \
+ '--postimport=-[Run a command after import]' \
+ '--uscan[Use uscan to fetch the new upstream version]' \
+ '*:file:_files'
+
+ # TODO: pass only one tarball
+ # TODO: Do not complete files when uscan option is enabled
+}
+
+_gbp-pq() {
+ __gbp_common_options
+ _arguments \
+ '(--patch-numbers --no-patch-numbers)--patch-numbers[Add numbers to patch files]' \
+ '(--patch-numbers --no-patch-numbers)--no-patch-numbers[Do not add numbers to patch files]' \
+ '--topic=-[Topic to use when importing a single patch]' \
+ '--time-machine=-[Go back N commits trying to apply patch queue]'
+
+ local -a pqcommands
+ pqcommands=(
+ 'import:Create a patch queue branch'
+ 'export:Export the patches on the patch-queue branch'
+ 'rebase:Rebase the patch-queue branch against the current branch'
+ 'drop:Drop the patch queue'
+ 'apply:Add a single patch to the patch-queue'
+ 'switch:Switch to the patch-queue branch if on the base branch and viceversa'
+ )
+ # TODO: only display these commands once
+ _describe -t pqcommands gbp-pq pqcommands
+}
+
+_gbp-pull() {
+ __gbp_common_options
+ __gbp_branch_options
+ _arguments \
+ '--force[Update even non fast-forward]' \
+ '--redo-pq[Rebuild the patch queue]' \
+ '--ignore-branch[Dont care if on a detached state]' \
+ '--depth=-[Depth for deepening shallow clones]'
+}
+
+_gbp "$@"
+
+
+
+__gbp_common_options() {
+ local prefix="$1"
+ # these can't be prefixed
+ _arguments '--help[Show help]' \
+ '--version[Show version information]'
+
+ _arguments "--${prefix}verbose[Verbose execution]" \
+ "--${prefix}color=-[Use colored output]:color:(on auto off)"
+
+}
+
+__gbp_branch_options() {
+ local prefix="$1"
+ _arguments \
+ "--${prefix}debian-branch=-[The branch the Debian package is being developed on]" \
+ "--${prefix}upstream-branch=-[The branch the upstream sources are put onto]" \
+ "--${prefix}pristine-tar[Track pristine tar branch]"
+}
+
+__gbp_tag_format_options() {
+ local prefix="$1"
+ _arguments \
+ "--${prefix}debian-tag=-[format string for debian tags]" \
+ "--${prefix}upstream-tag=-[format string for upstream tags]"
+}
+
+__gbp_tag_sign_options() {
+ local prefix="$1"
+ _arguments \
+ "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}sign-tags[GPG sign all generated tags]" \
+ "(--${prefix}sign-tags --${prefix}no-sign-tags)--${prefix}no-sign-tags[Do not GPG sign generated tags]" \
+ "--${prefix}keyid=-[GPG keyid to sign tags with]:GPG key:"
+}
+
+_gbp() {
+ local curcontext="$curcontext" state line
+ typeset -A opt_args
+ _arguments -C \
+ ':command:->command' \
+ '*::options:->options' \
+
+ case $state in
+ (command)
+ #breaks if defined outside the func
+ local -a subcommands
+ subcommands=(
+ 'buildpackage:Build a Debian package'
+ 'clone:Clone a Git repository from a remote and set up the necessary branch tracking.'
+ 'create-remote-repo:Create a remote Git repository'
+ 'dch:Generate the debian/changelog from Git commit history'
+ 'import-dsc:Import a single Debian source package'
+ 'import-dscs:Import multiple Debian source packages'
+ 'import-orig:Import a new upstream tarball'
+ 'pq:Manage debian/patches using Git rebase'
+ 'pull:Update a Git repository from a remote'
+ )
+
+ _describe -t commands gbp subcommands
+ ;;
+ (options)
+ local funcname
+ funcname=_gbp-$line[1]
+ if type $funcname | grep -q "shell function" ; then
+ $funcname
+ fi
+ ;;
+ esac
+}
+
+_gbp-buildpackage() {
+ __gbp_common_options git-
+ __gbp_branch_options git-
+ __gbp_tag_format_options git-
+ __gbp_tag_sign_options git-
+ _arguments \
+ '--git-ignore-new[build with uncommitted changes in the source tree]' \
+ '--git-no-ignore-new[negates --git-ignore-new]' \
+ '--git-tag[create a tag after a successful build]' \
+ '--git-tag-only[do not build, only tag and run the posttag hook]' \
+ '--git-retag[do not fail if the tag already exists]' \
+ '--git-force-create[force creation of orig.tar.gz]' \
+ '--git-no-create-orig[do not create orig.tar.gz]' \
+ '--git-tarball-dir=-[location to look for external tarballs]:tarball directory:_files -/' \
+ '--git-compression=-[compression type]:compression:(auto gzip bzip2 lzma xz)' \
+ '--git-compression-level=-[set compression level]:level:(1 2 3 4 5 6 7 8 9)' \
+ '--git-ignore-branch[build although debian-branch != current branch]' \
+ '--git-no-ignore-branch[negates --git-ignore-branch]' \
+ '--git-builder=-[command to build the Debian package]:command:' \
+ '--git-cleaner=-[command to clean the working copy]:command:' \
+ '--git-prebuild=-[command to run before a build]:command:' \
+ '--git-postbuild=-[hook run after a successful build]:command:' \
+ '--git-posttag=-[hook run after a successful tag operation]:command:' \
+ '--git-pbuilder[invoke git-pbuilder for building]' \
+ '--git-no-pbuilder[negates --git-pbuilder]' \
+ '--git-dist=-[build for this distribution when using git-pbuilder]:distribution:' \
+ '--git-arch=-[build for this architecture when using git-pbuilder]:architecture:' \
+ '--git-export-dir=-[before building the package export the source into this directory]:directory:_files -/' \
+ '--git-export=-[export treeish object instead of HEAD]:treeish:' \
+ '--git-dont-purge[retain exported package build directory]' \
+ '--git-overlay[extract orig tarball when using export-dir option]' \
+ '--git-no-overlay[negates --git-overlay]' \
+ '--git-notify=-[Send a desktop notification after build]:notify:(on auto off)' \
+ '*:Other options:_dpkg-buildpackage'
+}
+
+_gbp-clone() {
+ __gbp_common_options
+ __gbp_branch_options
+ _arguments \
+ '--all[Track all branches, not only debian and upstream]'
+}
+
+_gbp-create-remote-repo() {
+ __gbp_common_options
+ _arguments \
+ '--remote-url-pattern=-[Where to create remote repository]' \
+ '--remote-name=-[What name git will use when refering to that repository]' \
+ '--template-dir=-[Template dir to pass to git init]' \
+ '--remote-config=-[Name of config file section to specify params]' \
+ '(--track --no-track)--track[Set up branch tracking]' \
+ '(--track --no-track)--no-track[Do not set up branch tracking]'
+
+}
+
+_gbp-dch () {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+
+ _arguments \
+ '--ignore-branch[build although debian-branch != current branch]' \
+ '--since=-[Start point for reading commits]:commitish:' \
+ '--auto[Guess the last commit documented in the changelog]' \
+ '(--meta --no-meta)--meta[Parse meta tags]' \
+ '(--meta --no-meta)--no-meta[Do not parse meta tags]' \
+ '--meta-closes=-[What meta tags to look for to generate bug-closing changelog entries]' \
+ '--meta-closes-bugnum=-[What bug number format to look for to generate bug-closing changelog entries]' \
+ '(--full --no-full)--full[Include the full commit message]' \
+ '(--full --no-full)--no-full[Do not include the full commit message]' \
+ '(--snapshot -S)'{-S,--snapshot}'[Create a snapshot release entry]' \
+ '--snapshot-number=-[Python expression that gets eval()ed to the new snapshot number]' \
+ '(--release -R)'{-R,--release}'[Remove any snapshot release banners]' \
+ '(--new-version -N)'{-R,--release}'=[Specify changelog version]' \
+ '--team[Create a team upload entry]' \
+ '--bpo[Increment the release number for a backports upload]' \
+ '--nmu[Increment the release number for a NMU upload]' \
+ '--qa[Increment the release number for a QA upload]' \
+ '--distribution=-[Set the distribution field]' \
+ '--force-distribution[Force distribution]' \
+ '--urgency=-[Set the upload urgency]' \
+ '--git-log=-[Options passed to git log]' \
+ '--id-length=-[Number of commit id digits to include]' \
+ '--ignore-regex=-[Ignore matching commit lines]' \
+ '--git-author[Use git name configuration for changelog signature]' \
+ '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Merge commits by maintainer]' \
+ '(--multimaint-merge --no-multimaint-merge)--multimaint-merge[Do not merge commits by maintainer]' \
+ '--spawn-editor=[Spawn an editor]:when:(always never snapshot release)' \
+ '--commit-msg=[Commit message format string]' \
+ '--commit[Commit the generated changelog]' \
+ '*:Paths:_files -/'
+}
+
+_gbp-import-dsc() {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+ __gbp_tag_sign_options
+ _arguments \
+ '--filter=-[Filter out files]' \
+ '--allow-unauthenticated[Skip signature verification on downloads]' \
+ '--allow-same-version[Import a package with the same debian version]' \
+ '--author-is-committer[Use the author identity as committer identity]' \
+ '--author-date-is-committer-date[Use author date as commit date]' \
+ '*:package:_files -g "*.dsc"'
+ # TODO: complete source package names
+ # TODO: pass only one tarball/source package name
+}
+
+_gbp-import-dscs() {
+ # same options
+ _gbp-import-dsc
+ _arguments \
+ '--debsnap[Fetch snapshots from snapshots.debian.org]' \
+ '--ignore-repo-config[Ignore options in gbp.conf]'
+ # TODO: multiple dscs or one source package name + debsnap
+}
+
+_gbp-import-orig() {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+ __gbp_tag_sign_options
+ _arguments \
+ '(--upstream-version -u)'{--upstream-version,-u}'=[The upstream version number]' \
+ '--merge[Merge the upstream branch into the debian branch]' \
+ '--upstream-vcs-tag=-[Add a tag as an additional parent to the upstream tarball commit]' \
+ '--import-msg=-[Commit message format string]' \
+ '--filter=-[Filter out files]' \
+ '--filter-pristine-tar[When filtering also filter out of pristine-tar tarballs]' \
+ '(--symlink-orig --no-symlink-orig)--symlink-orig=[Create a symlink with a debian-compliant name]' \
+ '(--symlink-orig --no-symlink-orig)--no-symlink-orig=[Do not create a symlink with a debian-compliant name]' \
+ '--postimport=-[Run a command after import]' \
+ '--uscan[Use uscan to fetch the new upstream version]' \
+ '*:file:_files'
+
+ # TODO: pass only one tarball
+ # TODO: Do not complete files when uscan option is enabled
+}
+
+_gbp-pq() {
+ __gbp_common_options
+ _arguments \
+ '(--patch-numbers --no-patch-numbers)--patch-numbers[Add numbers to patch files]' \
+ '(--patch-numbers --no-patch-numbers)--no-patch-numbers[Do not add numbers to patch files]' \
+ '--topic=-[Topic to use when importing a single patch]' \
+ '--time-machine=-[Go back N commits trying to apply patch queue]'
+
+ local -a pqcommands
+ pqcommands=(
+ 'import:Create a patch queue branch'
+ 'export:Export the patches on the patch-queue branch'
+ 'rebase:Rebase the patch-queue branch against the current branch'
+ 'drop:Drop the patch queue'
+ 'apply:Add a single patch to the patch-queue'
+ 'switch:Switch to the patch-queue branch if on the base branch and viceversa'
+ )
+ # TODO: only display these commands once
+ _describe -t pqcommands gbp-pq pqcommands
+}
+
+_gbp-pull() {
+ __gbp_common_options
+ __gbp_branch_options
+ _arguments \
+ '--all[Update all remote-tracking branches that have identical name in the remote]' \
+ '--depth=-[Depth for deepening shallow clones]' \
+ '--force[Update even non fast-forward]' \
+ '--ignore-branch[Dont care if on a detached state]' \
+ '--no-ignore-branch[Negates --ignore-branch]' \
+ '--no-pristine-tar[Negates --pristine-tar]' \
+ '--no-track-missing[Negates --track-missing]' \
+ '--redo-pq[Rebuild the patch queue]' \
+ '--track-missing[Track missing remote branches, default is "False"]'
+}
+
+_gbp-push() {
+ __gbp_common_options
+ __gbp_branch_options
+ __gbp_tag_format_options
+ _arguments \
+ '--dry-run[Dry run, do not push]' \
+ '--ignore-branch[Dont care if on a detached state]' \
+ '--no-ignore-branch[Negates --ignore-branch]'
+}
+
+_gbp-import-ref() {
+ __gbp_common_options
+ __gbp_tag_sign_options
+ _arguments \
+ '--debian-branch=-[The branch the Debian package is being developed on]' \
+ '--keyid=-[Use this keyid for gpg signing tags]' \
+ '--merge-mode=-[How to fold the upstream commits onto the Debian packaging branch]' \
+ '--no-rollback[Do not rollback changes in case of an error]' \
+ '--postimport=-[Run cmd after the import]' \
+ '--rollback[Rollback changes in case of an error]' \
+ '--upstream-branch=-[The branch the upstream sources are put onto]' \
+ '--upstream-tag=-[Format string for upstream tags]' \
+ '--upstream-tree=-[What to merge into the debian-branch]:tree:(BRANCH TAG TREEISH)' \
+ '--upstream-version=-[The upstream version to merge]'
+}
+
+_gbp-export-orig() {
+ __gbp_common_options
+ _arguments \
+ '--component=-[Component name for additional tarballs]' \
+ '--compression=-[Compression type]:compression:(auto gzip bzip2 lzma xz)' \
+ '--compression-level=-[Set compression level]:level:(1 2 3 4 5 6 7 8 9)' \
+ '--force-create[Force creation of orig tarball]' \
+ '--no-pristine-tar[Negates --pristine-tar]' \
+ '--no-submodules[Negates --submodules]' \
+ '--pristine-tar[Use pristine-tar to create orig tarball]' \
+ '--submodules[Transparently handle submodules in the upstream tree]' \
+ '--tarball-dir=-[Location to look for external tarballs]:tarball directory:_files -/' \
+ '--upstream-branch=-[The branch the upstream sources are put onto]' \
+ '--upstream-signatures=-[Use upstream signature]' \
+ '--upstream-tag=-[Format string for upstream tags]' \
+ '--upstream-tree=-[What to merge into the debian-branch]:tree:(BRANCH TAG TREEISH)'
+}
+
+_gbp-pristine-tar() {
+ __gbp_common_options
+ _arguments \
+ '--component=-[Component name for additional tarballs]' \
+ '--upstream-tag=-[Format string for upstream tags]'
+}
+
+_gbp-tag() {
+ __gbp_common_options
+ __gbp_tag_sign_options
+ _arguments \
+ '--debian-branch=-[The branch the Debian package is being developed on]' \
+ "--debian-tag=-[Format string for debian tags]" \
+ "--debian-tag-msg=-[Format string for signed debian-tag messages]" \
+ '--git-no-ignore-branch[Negates --git-ignore-branch]' \
+ '--ignore-branch[Dont care if on a detached state]' \
+ '--ignore-new[Build with uncommitted changes in the source tree]' \
+ '--no-ignore-new[Negates --git-ignore-new]' \
+ '--posttag=-[Hook run after a successful tag operation]:command:' \
+ '--retag[Do not fail if the tag already exists]'
+}
+
+_gbp-config() {
+ __gbp_common_options
+}
+
+_gbp "$@"