From the Canyon Edge -- :-Dustin

Thursday, October 21, 2010

Bikeshed: bch (seed and edit bzr changelog)

Here's another tool I use every single day, many times per day: bch.

I maintain all of my projects/packages in bzr itself, using debian/changelog to describe changes to both the source code and the packaging.

I used to use dch to edit the current changelog entry, starting a new line with an asterisk, and then listing each path of each file I've changed, followed by a colon, and then a description of my changes.

However, I can easily use bzr diff to get a good list of the files I've changed, use sort to arrange them in alphabetical order, print a comma-separated lists, and use dch to insert that list into debian/changelog. All I have to do is describe the change, save, and close the file.

Note that I typically follow bch with debcommit, which uses that same changelog entry when committing to bzr. It's really, really handy and convenient!

Try it:
  1. Grab some source code
    bzr branch lp:bikeshed

  2. Make some changes
    cd bikeshed
    echo foo > bar
    bzr add bar
    echo "" >> pbput

  3. Add a changelog entry

If you find this useful, install the bikeshed package from Natty, or from the Bikeshed PPA for other versions of Ubuntu.


No comments:

Post a Comment

Please do not use blog comments for support requests! Blog comments do not scale well to this effect.

Instead, please use Launchpad for Bugs and StackExchange for Questions.