[git-buildpackage] Usage inside pipelines / branches

Denny Fuchs linuxmail at 4lin.net
Tue Jun 7 15:01:18 CEST 2022


Hello Guido,

Am 07.06.22 um 14:15 schrieb Guido Günther:
> I have to say that I don't understand your intended workflow but maybe
> "gbp import-ref" helps as it allows you to take a branches content 1:1
> and replace everything but the debian/ folder (which is kept verbatim).
> This makes sure you don't get any  merge conflicts.

the flow is: doing stuff on develop branch, merge develop into Master 
branch.

So, how should look like the gbp import-ref command ?

I used also ..

gbp import-ref --upstream-tree=BRANCH -u master ... but fails and 
changes will be reverted ...

but I tried now also:

gbp import-ref --upstream-tree=BRANCH -u master --merge-mode=replace

which looks really better ...

but I'm unsure .. how to arrange now the commands in the right order

so, what about:

$ git checkout debian/${DEBIAN_VERSION}
$ gbp import-ref --upstream-tree=BRANCH -u master --merge-mode=replace
$ gbp dch -R -N $DEB_VERSION --spawn-editor=never --commit
$ mk-build-deps --install --remove --tool="$TOOL_ARGS" debian/control
$ gbp buildpackage --git-upstream-tag='v%(version)s'
--git-upstream-branch=master \
--git-ignore-branch --git-upstream-tree=BRANCH \
--git-ignore-new --build=all -us -uc -rfakeroot \
--lintian-opts profile debian
$ gbp tag --debian-tag="debian/${DEBIAN_VERSION}/%(version)s" --retag
$ gbp push --debian-branch=debian/${DEBIAN_VERSION} \
git@$CI_SERVER_HOST:$CI_PROJECT_PATH.git
$ git push --follow-tags git@$CI_SERVER_HOST:$CI_PROJECT_PATH.git

for a release, as example ?

Thanks for the advise :-)

cu denny


More information about the git-buildpackage mailing list