Add subfolder from XPR to your output

pieterjan_vdw
Posts: 32
Joined: Wed Jun 20, 2018 11:30 am

Add subfolder from XPR to your output

Post by pieterjan_vdw » Tue Jan 29, 2019 4:18 pm

I have the current folder structure in my Oxygen project:
  • nl
    • abc.ditamap
    • def.ditamap
  • fr
    • abc.ditamap
    • def.ditamap
I would to set up 1 OxygenXML transformation scenario to an output folder: ${pd}/_output/???? where:
- the files for the nl folder are stored in the nl folder
- the files from the fr folder are stored in the fr folder

Example:
${pd}/_output/nl/def.pdf
${pd}/_output/nl/abc.pdf
${pd}/_output/fr/def.pdf
${pd}/_output/fr/abc.pdf

Do you have a variable available to do this?

Thanks!

Radu
Posts: 7528
Joined: Fri Jul 09, 2004 5:18 pm

Re: Add subfolder from XPR to your output

Post by Radu » Tue Jan 29, 2019 4:23 pm

Hi Pieterjan,

We do not have a specific editor variable for this but we do have the xpath_eval editor variable in which you can call xpath functions on other editor variables, something like:

topic13107.html

so using it you may be able to achieve what you want.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

pieterjan_vdw
Posts: 32
Joined: Wed Jun 20, 2018 11:30 am

Re: Add subfolder from XPR to your output

Post by pieterjan_vdw » Tue Jan 29, 2019 4:44 pm

Thanks Radu! Works like a charm!
This is what my settings is looking like: ${pd}\_output\pdf\${xpath_eval(substring-after('${cfd}','documentation*'))}\${cfn}.pdf

documentation* is the name of my main folder.

Post Reply