- From: Imsieke, Gerrit, le-tex <gerrit.imsieke@le-tex.de>
- Date: Sun, 15 Oct 2017 15:21:17 +0200
- To: xproc-dev@w3.org
Hi David, I’m not sure whether I understood the issue at hand. Anyway, I created this gist: https://gist.github.com/gimsieke/f3b5534658b2f7240d579230ca17fc4a If you invoke it like (assuming you have a front-end script called calabash.sh): calabash.sh -p foo=bar -p other-param=other-val test-param-manipulation.xpl the transformed parameters will be stored as manipulated-params.xml and look like this: <c:param-set xmlns:c="http://www.w3.org/ns/xproc-step"> <c:param name="param" value="param"/> <c:param name="foo" namespace="" value="baz"/> </c:param-set> The output will be like: <out xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:c="http://www.w3.org/ns/xproc-step"> <param name="foo" value="baz"/> <param name="other-param" value=""/> <param name="param" value="param"/> </out> Does looking at the pipeline answer your questions? If not, I’ll be back in approx. 2 hours to answer more. Gerrit On 15.10.2017 06:22, David Cramer wrote: > The wonderful thing about posting to a mailing list is that it so often > inspires you to see the obvious solution immediately /after/ you hit > Send. Occasionally, the act of composing the message inspires me to see > the solution before I hit Send, but not this time. > > Obviously, I just need to explicitly declare the result of my > transformation as the input for the parameters port for any subsequent > xslt steps or their wrappers: > > <p:xslt> > <p:input port="parameters" kind="parameter"> > <p:pipe port="result" step="param-fixup"/> > </p:input> > ... > > I'd been trying to do that for p:group, but only a step can have a > parameters port. > > Regards, > David > > On 10/14/17 11:03 PM, David Cramer wrote: >> Some time ago, I learned on this list how to fetch values from the >> c:param-set that comes in on the parameter port to use in p:variable >> values in my pipeline: >> https://lists.w3.org/Archives/Public/xproc-dev/2012May/0005.html >> >> Now I'm attempting to transform that c:param-set before my xslt steps >> consume it. Transforming the c:param-set is easy enough by taking as >> input the result of the Geert Josten's ut:parameters utility step: >> https://github.com/grtjn/xproc-ebook-conv/blob/master/src/nl/grtjn/xproc/util/utils.xpl#L374 >> >> However, once the c:param-set is transformed, I haven't figured out >> how to make subsequent steps in the pipline use the manipulated version. >> >> I could manipulate the parameters in the scripts that call calabash or >> in the xslts, but it feels like I should be able to run the >> c:param-set thorough an xslt and then use the result of that in the >> rest of my pipline. >> >> Is this possible? >> >> Btw., I'm running xmlcalabash-1.1.16-97 >> >> Regards, >> David >> >> > -- Gerrit Imsieke Geschäftsführer / Managing Director le-tex publishing services GmbH Weissenfelser Str. 84, 04229 Leipzig, Germany Phone +49 341 355356 110, Fax +49 341 355356 510 gerrit.imsieke@le-tex.de, http://www.le-tex.de Registergericht / Commercial Register: Amtsgericht Leipzig Registernummer / Registration Number: HRB 24930 Geschäftsführer: Gerrit Imsieke, Svea Jelonek, Thomas Schmidt, Dr. Reinhard Vöckler ------------------------------------------------------------------------------ Meet us at Frankfurt Book Fair Hall 4.2, L 72. More at https://www.le-tex.de/en/buchmesse.html
Received on Sunday, 15 October 2017 13:21:52 UTC