git-merge-dch: A Git Merge Driver for Debian Changelog Files

Speaker: Alper Nebi Yasak

Track: Standards and Procedures

Type: Long talk (45 minutes)

Room: Aula Magna - FADU

Time: Jul 25 (Sat): 10:00

Duration: 0:45

One thing that annoys me quite frequently when doing Debian-related development is having to manually resolve conflicts on the debian/changelog file every time the upstream code gets updated. Changelogs appear to have a simple format: a series of entries each with a few independent lines per change. Fixing merge conflicts should be automatic and invisible. I should never get an email from Salsa for a debian/changelog conflict in my merge requests just because the maintainer added a new change or finalized an entry. Maybe except in extreme cases.

One would expect git to handle these conflicts gracefully, but it simply gives up when seeing a context mismatch, which happens almost every time. Even worse, it will happily and silently merge changes into an already released changelog entry. There is dpkg-mergechangelogs, but it’s fundamentally the wrong tool to use because it assumes finalized non-conflicting version numbers and changelog entries, the opposite of what happens in development e.g. when rebasing your changes onto upstream packaging.

Eventually I got annoyed enough to start writing something that can properly merge debian/changelog files. It’s not as simple as it sounds, and my affinity to find edge cases makes it worse. In the talk I’ll try to define the problem domain, highlight some weird cases with life-like examples, and demonstrate spooky action at a distance. I don’t know if the merge driver itself will be finished in time for the talk, in which case this will also serve as a request for help.

URLs