titanium-backup-merger, a tool for merging SMS/MMS backups

In a previous post, I mentioned the lack of a feature in Titanium Backup Pro's otherwise excellent xml-based backup tool: a way to merge multiple backup files. This can be done manually, as I detailed there, but what if you have multiple files with hundreds of threads that may or may not contain duplicates?

That's precisely the predicament I found myself in, so... I created the 'lxml monstrosity' I portended in the end of that post!

It's available on my github. You'll need python and lxml to run it.

It takes 2 or more Titanium SMS/MMS backup xml files as input and merges them all together into one, conveniently ignoring exact duplicates. This does not mean messages that have the same text contents, this means total duplicates - messages that are the same in content, date, time and address (phone number). This is common when merging multiple versions of backups you made at different points in time - and what prompted me to code this up.