Putting Stow back together
Posted by jtakeda on 09 Jul 2018 in Activity log
Met with MDH today to discuss the plan for putting Stow back together. Most of the big concerns were regarding rendition elements and pointers. I've been able to implement the first bit of the plan today: getting the renditions rationalized. It's a multi-step process like so:
- Create an XSLT based off of each include (i.e. find all the documents with mol-include, resolve those includes, and then process each of the included documents). This uses pre-existing code for the standalone.
- Copy over the XSLT and its corresponding document to a temporary directory
- Use the pre-existing for-each target to apply the XSLT to the XML file (it takes longer than I'd like, however, but I don't think there's anyway to make it go faster)
- Now process the files that have the includes and bring in the stuff that's meant to be included; since all of the rendition selectors are processed, it's simple to get the style values from the rendition in the header.
I'm currently doing this after the original build, but I don't know if that's the right time to do it; the issue is that it breaks if you try to do in quick and subset (since there are now no documents that have to be resolved); this isn't great if you're trying to rebuild the reconstituted Stow in a smaller build process. I'll have to investigate that.