I have a project on Launchpad that consists of a single branch (trunk). I would like to create a second branch that contains the Debian packaging for the project (with the intent of creating a build recipe that merges it into the main branch before building).

I've done this before by just pushing a local branch to lp:~me/project_name/debian. However, this stacks the branch with trunk, which I don't want (it becomes impossible to delete trunk without deleting the Debian packaging branch - a restriction that has caused problems before).

What is the proper way to do this?


You'll need to create a new, clean branch with bzr init, then copy your files into it. Then bzr add, commit and push from the new branch.

  • I'm afraid it still created a stacked branch. – Nathan Osman Jun 19 '12 at 1:45
  • Create a separate repository then elsewhere, outside of your project name. I have numerous junk branches on my username with numerous other debian stuffs (branches named debian-[application]) – Thomas Ward Jun 20 '12 at 15:11

The stacking is handled on the Launchpad side. Even if you can't remove the trunk later, you can still rename it out of place (and create a new trunk) and hide it by marking it deprecated.


If you just want to nest the "debian" subdirectory with packaging info, use a build recipe pointing to trunk source branch in LP and add a "nest-part" line to add packaging info as it's described in: https://help.launchpad.net/Packaging/SourceBuilds/Recipes

Something like this:

# bzr-builder format 0.3 deb-version 1.0+{revno}
nest-part packaging lp:~some-person/some-project/trunk-with-packaging debian debian

If the source branch has no compilation/build errors, your nested debian info will take care of packaging.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.