Recently I worked on putting together a custom XML Xcode Instrument and when facing 1000s of lines of flat XML in a single file I stopped and made a detour to create a little Swift-powered extension that plugs into Xcode's pre and post actions.
I just pushed a blog post with details, probably interesting for other folks working on tooling: Extending Xcode with power-ups