Building Packages with git-buildpackage suite: Version: 0.7.0-tizen20151027 |
---|
gbp pq-rpm [--version
] [--help
] [--verbose
] [--color=
[auto|on|off]] [--color-scheme=
COLOR_SCHEME] [--pq-branch=
BRANCH-NAME] [--packaging-dir=
DIRECTORY] [--spec-file=
FILEPATH] [--upstream-tag=
TAG-FORMAT] [--force
] [--[no-]patch-numbers
] [--import-files=
FILES] [--export-rev=
TREEISH] [--patch-compress=
THRESHOLD] [--patch-ignore-path=
REGEX] [--patch-squash=
COMMITISH] [--new-packaging-dir=
DIRECTORY] [--retain-history
] drop
| export
| import
| rebase
| switch
| apply
| convert
gbp pq-rpm helps in managing patches and development branch(es) for packages that are maintained with gbp. It designed to be used for packages that are maintained using the "orphan-packaging" model. gbp pq-rpm has multiple subcommands, or actions, for working with the branches and patches.
gbp pq-rpm makes it easy to do source code development on a separate development branch (patch-queue branch in Debian git-buildpackage terms). For example, if the packaging files would be stored in master the associated development branch would be development/master.
import | Create a development (patch-queue) branch by applying all patches from the packaging branch on top of the upstream version. The patches must apply without fuzz. |
export | Export patches from the development branch into the packaging branch. It generates patches (one-per-commit) from the development branch and updates the spec file accordingly. It doesn't automatically commit the changes though - they need to verified and committed manually. |
rebase | Switch to the development branch and rebase it against the current upstream version (indicated in the spec file of the associated packaging branch). |
drop | Drop (delete) the development branch associated to the current branch. For example, you're on branch foo this would drop branch development/foo. |
apply | Add a single patch to the development branch - similar to using git-am. |
switch | Switch between the development branch and the associated packaging branch. |
convert | Convert a package from the "joint-packaging" maintenance model and
git-layout to the "orphan-packaging" model. It takes the content of
the packaging directory, auto-generates patches and puts these into a
new orphan packaging branch. You can use the
|
--version | Print version of the program, i.e. version of the git-buildpackage suite |
-v , --verbose | Verbose execution |
-h , --help | Print help and exit |
--color= [auto|on|off] | Whether to use colored output. |
--color-scheme= COLOR_SCHEME | Colors to use in output (when color is enabled). The format for
COLOR_SCHEME is
'<debug>:<info>:<warning>:<error>'.
Numerical values and color names are accepted, empty fields imply
the default color. For example,
|
--pq-branch =BRANCH_NAME | Name (format string) of the development (patch-queue) branch. The following string fields are accepted: "%(branch)s" (the base branch, i.e. the packaging branch that the development branch is associated to), "%(upstreamversion)s" (the upstream version), "%(release)s" (the rpm patchlevel, i.e. Release), "%(version)s" (full rpm package version). |
--packaging-dir= DIRECTORY | Subdirectory that contains the RPM packaging files. |
--spec-file= FILEPATH | Relative path to the spec file to use. Special value
auto causes gbp to search and guess.
Other values cause the |
--upstream-tag= TAG-FORMAT | Use this tag format when looking for tags of upstream versions, default is upstream/%(version)s. |
--force | Import even if the development (patch-queue) branch already exists. Only valid for the import action. |
--import-files= FILES | Comma-separated list of additional file(s) to import from packaging branch. These will appear as one monolithic patch in the development (patch-queue) branch. By default, the local gbp conf files are imported in order to try to ensure that gbp sees the same settings on the development (pq) branch as on the packaging branch. |
--export-rev= TREEISH | Export patches from TREEISH instead of the default which is HEAD of the development (patch-queue) branch. |
--patch-compress= THRESHOLD | Compress patches larger than given THRESHOLD bytes. Special value 0 disabled patch compression. |
--patch-ignore-path= REGEX | Exclude changes to path(s) matching REGEX in patch generation. |
--patch-squash= COMMITISH | Squash commits up to the given COMMITISH into one monolitic diff. Could be used if one wants to squash commits from an upstream release up to a stable update into a single diff (commits on top of the stable would generate one patch per commit as usual). The format is '<commit_ish>[:<filename_base>]', i.e. commitish optionally followed by a colon and the desired filename base for the diff (suffix '.diff' is automatically added by gbp). Magic word 'HEAD' translates to the patch-export-treeish when given as the squash-point. This allows one to configure gbp to always squash all commits into one monolithic diff. |
--[no-]patch-numbers | Whether the patch files should start with a number or not. |
--new-packaging-dir= DIRECTORY | Directory where packaging files are put in the new orphan packaging
branch after convert. If |
--retain-history | Try to preserve as much history as possible when converting. That is, for each commit in the old branch create one corresponding commit in the new orphan packaging branch. However, commits that will not generate any changes are skipped (i.e. no empty commits are generated) - these are caused e.g. by changes in files that are ignored by patch-generation. |
When exporting patches from a patch-queue branch gbp pq-rpm will look at the commit message for special tags it recognizes. All tags need to start at the first column and require at least one whitespace after the colon.
Gbp-Rpm: Ignore | Ignores the commit, no patch is generated out of it. |
Gbp-Rpm: If <expression> | Conditional patch. Put patch inside "%if <expression>" in the spec file. |
Gbp-Rpm: IfArch<expression> | Conditional patch. Put patch inside "%ifarch <expression>" in the spec file. |
For example, the following commit message:
Fix around a problem in Fedora which is not applicable elsewhere. Gbp-Rpm: If 0%{?fedora}
Will result something like this in the spec file:
# 0001-Fix-around-a-problem-in-Fedora.patch %if 0%{?fedora} %patch0 -p1 %endif
<<< gbp-import-srpm | gbp-rpm-ch >>> |