Making a changelog

Most extragear applications need to make there own changelog, just before they release a new tarball. In my projects I had a little script for doing that. Each commits gets an entry in the ChangeLog file and is associated with the real name of that person. I always use the diff from the ChangeLog file to fill the NEWS file with the highlights of the new release.

To get rid of the duplication of maintaining the script in each of my projects, I just generalized it a bit and moved it to kdesdk/scripts so everyone can use it. Just run in from the folder you want the changelog in. Optionally add a parameter to a subfolder if you only want the changes from that folder.

How it works? It’s simple:

extragear/pim/mailody$ svn2log.sh
Fetching committers...                                  
Creating changelog...
[...]
extragear/pim/mailody$ svn diff ChangeLog | diffstat
 ChangeLog | 1911 +++++++++++++++++++++++++++++++++++++++++---------------------
 1 file changed, 1275 insertions(+), 636 deletions(-)
extragear/pim/mailody$ head ChangeLog
2009-09-19 13:43 +0000 [r1025714]  Christophe Giboudeaux [..]@gmail.com

 * trunk/extragear/pim/mailody/CMakeLists.txt: Coding style + Remove
 the REQUIRED keyword

2009-09-19 13:26 +0000 [r1025707]  Christophe Giboudeaux [..]gmail.com

 * trunk/extragear/pim/mailody/kontact/CMakeLists.txt: Cleanup

Hope this is usefull for others.

5 Comments

  1. Do you have an idea, how to implement this for gitsvn users?

  2. No idea.

  3. @joWenn git svn users just type ‘git log’ ;)
    The changes command of my own tool ‘vng’ (on gitorious) looks similar too and works on git repositories. It has the added advantage to show the files changed and the amount of lines changed like this;

    Thu Sep 10 22:14:05 2009 Thomas Zander <[...]@kde.org>
    ID 7b598126c3e4b6dc8054b3a840b1b0afced13103
    Don’t ignore the other 2 enum values totally,

    M kword/part/frames/KWTextDocumentLayout.cpp -2 +2

  4. can we assume progress on mailody from the excerpt above?

  5. Yes, I picked it up again this weekend, I’m expecting to work on it for a the coming month or so. I’ll blog.