eerohele / saxon-gradle

A Gradle plugin for running XSLT transformations with Saxon
MIT License
16 stars 6 forks source link

Run multiple chained stylesheets #12

Open tofi86 opened 6 years ago

tofi86 commented 6 years ago

Hi, thanks for the useful plugin.

It would be great If one could run multiple chained stylesheets instead of defining multiple tasks for a chained transformation scenario.

I imagine something like this:

xslt {
    stylesheet 'stylesheet_step-1.xsl'
    stylesheet 'stylesheet_step-2.xsl'
    stylesheet 'stylesheet_step-3.xsl'
}

... where stylesheet_step-2.xsl would take the result from stylesheet_step-1.xsl as its input, and so on...

Do you think this is doable?

Thanks!

eerohele commented 6 years ago

Good idea! It should be doable — I'll look into it.

tofi86 commented 6 years ago

Awesome! Thanks a lot! 👍

tofi86 commented 6 years ago

I added a workaround code snippet in the Wiki: https://github.com/eerohele/saxon-gradle/wiki/How-To#how-to-run-an-xslt-pipeline-or-how-to-execute-the-plugin-multiple-times-with-different-paramters

eerohele commented 6 years ago

This is a bigger job than I originally anticipated. It's doable, but it would likely require a fairly heavy refactoring of the current codebase.

I'd like to do it, but it's unlikely I'll get to it in the near future. I'll keep thinking about it, though.