[[gbp]]
===  git-buildpackage

The *git-buildpackage* package offers many commands to automate packaging activities using the git repository.

* *git-import-dsc*: import the previous Debian source package to the git repository.
* *git-import-orig*: import the new upstream tar to the git repository.
* *git-dch*: generate the Debian changelog from the git commit messages.
* *git-buildpackage*: build the Debian binary package from the git repository. (alias *gbp*)
** The *--pristine-tar* option for the *git-buildpackage* command enables to store the upstream tarball in the same git repository.
** The *--uscan* option for the *git-buildpackage* command enables to download and commit the new upstream tarball into the git repository.
* *git-pbuilder*: build the Debian binary package from the git repository using the *pbuilder* package.
** The *cowbuilder* package is used as its backend.
* The *gbp-pq*, *git-dpm* or *quilt* (or alias *dquilt*) commands are used to manage quilt patches.
** The use of the *dquilt* command is the simplest to learn and requires you to commit the resulting files manually with the *git* command to the *master* branch.

The package history management with the *git-buildpackage* package is becoming the standard practice for most Debian maintainers.

See:

* https://wiki.debian.org/GitPackagingWorkflow
* https://wiki.debian.org/GitPackagingWorkflow/DebConf11BOF
* http://raphaelhertzog.com/2010/11/18/4-tips-to-maintain-a-3-0-quilt-debian-source-package-in-a-vcs/
* The *systemd* packaging practice documentation on http://anonscm.debian.org/gitweb/?p=pkg-systemd/systemd.git;a=blob;f=debian/README.source[Building from source].

