Scroll to navigation

git-deborig(1) git-deborig git-deborig(1)

NAME

git-deborig - try to produce Debian orig.tar using git-archive(1)

SYNOPSIS

git deborig [--force|-f] [--just-print|--just-print-tag-names] [--version=VERSION] [COMMITTISH]

DESCRIPTION

git-deborig tries to produce the orig.tar you need for your upload by calling git-archive(1) on an existing git tag or branch head. It was written with the dgit-maint-merge(7) workflow in mind, but can be used with other workflows.

git-deborig will try several common tag names. If this fails, or if more than one of those common tags are present, you can specify the tag or branch head to archive on the command line (COMMITTISH above).

git-deborig will override gitattributes(5) that would cause the contents of the tarball generated by git-archive(1) not to be identical with the commitish archived: the export-subst and export-ignore attributes.

git-deborig should be invoked from the root of the git repository, which should contain debian/changelog.

OPTIONS

Overwrite any existing orig.tar in the parent directory.
Instead of actually invoking git-archive(1), output information about how it would be invoked. Ignores --force.

The output is, one per line:

Note that running the git-archive(1) invocation outputted with this option may not produce the same output. This is because git-deborig takes care to disables git attributes otherwise heeded by git-archive(1), as detailed above.

Exits with status 6 (and an error message) if the tag situation is confusing or ambiguous, and the problem could be fixed by a config change.

Instead of actually invoking git-archive(1), or even checking which tags exist, print the tag names we would consider for the upstream version number in the first entry in the Debian changelog, or that supplied with --version.

The output is just a list, and omits information about tag priority order. Prefer --just-print, which uses a more sophisticated algorithm to select the correct tag.

Instead of reading the new upstream version from the first entry in the Debian changelog, use VERSION.

UPSTREAM TAG SELECTION

CONFIGURING DIRECT USE OF UPSTREAM TAGS

Normally, it is best to use upstream git tags directly, and not import upstream tarballs or retag upstream releases.

git-deborig tries to guess the right upstream tag, from the version number. By default it expects the real upstream tag to be version or vversion

You can override this by creating a debian/gbp.conf containing something like this:

 [export-orig]
 upstream-tag = foo-%(version)s

This will also make gbp export-orig and Debian Salsa CI use the nominated upstream tag directly.

If you want new upstream releases shown on Debian QA packages, or to use uscan, you need to configure uscan separately. See uscan(1).

If you use gbp import-orig instead (we recommend against that), git-deborig will use the tags created by gbp import-orig. Real upstream information is then provided to gbp invocations. consult its documentation.

ALGORITHM REFERENCE

git-deborig looks for tags in this order:

[export-orig] upstream-tag = ... in gbp.conf
This is the value which would also be used by gbp export-orig.

%(version)s is replaced with the upstream version number, transformed according to DEP-14. See gbp.conf(5) and Python 3 configparser for full details.

This is the tag format used by gbp import-orig's synthetic tarball imports, by default.
Finally, if exactly one of these tags exist, git-deborig will use it. If neither or both exist, it is an error.

SEE ALSO

git-archive(1), dgit-maint-merge(7), dgit-maint-debrebase(7)

AUTHOR

The original author of git-deborig and this manpage is Sean Whitton <spwhitton@spwhitton.name>. They are now maintained by others.

dgit+tag2upload team Debian Project