so we can pass the current branch to git-dch
# filter out files from tarball passed to pristine tar
#filter-pristine-tar = True
# hook run after the import:
-#postimport = git-dch -N%(version)s -S -a
+#postimport = git-dch -N%(version)s -S -a --debian-branch=$GBP_BRANCH
# emulate old behaviour of calling dch:
#postimport = dch -v%(version)s New Upstream Version
if has_epoch(cp):
epoch = '%s:' % cp['Epoch']
info = { 'version': "%s%s-1" % (epoch, version) }
- cmd = gbpc.Command(options.postimport % info, shell=True)()
+ env = { 'GBP_BRANCH': options.debian_branch }
+ cmd = gbpc.Command(options.postimport % info, extra_env=env, shell=True)()
except gbpc.CommandExecFailed:
raise GbpError, "Import of %s failed" % archive
except GbpNothingImported, err: