Page 1 of 1

ISSUE: Markdown output comes out as a single line

Posted: Wed Mar 11, 2020 1:13 am
by GHogarth
Starting from a DITA book, I have tried both the regular Markdown and the GitHub-flavored Markdown Transformations, and both produce the output as a single line, which renders all the output as if it was a *very* long title. :?
All the interior markup appears to be correct, there are just not the CRs to break the lines.
I'm sure it's just a setting I'm missing. The map is: <bookmap chunk='to-content'>

Re: ISSUE: Markdown output comes out as a single line

Posted: Wed Mar 11, 2020 8:53 pm
by Radu
Hi,

What version of Oxygen are you using and what DITA OT? Is it the DITA OT bundled with Oxygen or an external DITA OT installation?
I tried setting chunk=to-content on this sample bookmap we have OXYGEN_INSTALL_DIR/samples/dita/it-book/taskbook.ditamap, generated Markdown content and the markdown content was not generated on a single line, I opened the result in Oxygen and it seems to be proper Markdown content.

Regards,
Radu

Re: ISSUE: Markdown output comes out as a single line

Posted: Fri Mar 13, 2020 5:10 pm
by GHogarth
Hi Radu
<oXygen/> XML Editor 22.0, build 2020021016
DITA-OT ver 3.x as bundled
===========
Discovered if I rename the file to "abc123.MD", the file is handled correctly. "abc123.HTML" (what gets produced by the transform), comes in as an single line.
Is there a way to change the default extention applied as part of the transform?

Regards
Grant

Re: ISSUE: Markdown output comes out as a single line

Posted: Fri Mar 13, 2020 5:16 pm
by Radu
Hi Grant,

There is a registered issue I added to the DITA to MD publishing plugin to set the default output extension as "md":

https://github.com/jelovirt/org.lwdita/issues/65

but as it says on the issue you can edit the transformation scenario and in the "Parameters" tab set the "out.ext" parameter to ".md".

Regards,
Radu

Re: ISSUE: Markdown output comes out as a single line

Posted: Fri Mar 13, 2020 5:38 pm
by GHogarth
Thanks!
I'm confused though.
Per your bug [https://github.com/jelovirt/org.lwdita/issues/65]
I tried adding "out.ext" with a value of "md" (no quotes) to the transform, but it doesn't seem to have taken.
Am I editing the wrong place/file?
In ignorance and appreciation,
Grant

Re: ISSUE: Markdown output comes out as a single line

Posted: Fri Mar 13, 2020 6:24 pm
by Radu
Hi Grant,

Where exactly did you add this parameter? Also try to set its value to ".md" without the quotes but with that extra dot.

Regards,
Radu

Re: ISSUE: Markdown output comes out as a single line

Posted: Mon Mar 16, 2020 6:39 pm
by GHogarth
Hi Radu.
I added

Code: Select all

.md
as a parameter to my version of the markdown transformation scenario.
I had not used quotes, but also did not use the period; FWIW, adding the period made no difference in the output. <smile>

Grant

RESOLVED: Markdown output comes out as a single line

Posted: Mon Mar 16, 2020 6:39 pm
by GHogarth
Hi Radu.
I discovered that I also needed to set the

Code: Select all

transtype
value for the transformation to markdown to get the correct output format.
Grant

Re: ISSUE: Markdown output comes out as a single line

Posted: Tue Mar 17, 2020 7:57 am
by Radu
Hi Grant,

If in the Configure Transformation Scenarios dialog you press the New button and choose "DITA OT" transformation, the dialog which shows allows you to choose Markdown or Github-flavored Markdown transformation types. After this the scenario should already have information about the transtype without you needing to manually set a value for it in the Parameters list. So I'm not sure why this last step was necessary for you.

Regards,
Radu

Re: ISSUE: Markdown output comes out as a single line

Posted: Sat May 23, 2020 12:55 am
by willwolf
I want to output Markdown from DITA but I don't see Markdown as a transformation output option. Am I missing something? Thank you.

Re: ISSUE: Markdown output comes out as a single line

Posted: Mon May 25, 2020 6:32 am
by Radu
Hi,

Per my reply above, open the DITA Map in the DITA Maps Manager view and click the "Configure Transformation Scenarios" toolbar button.
If in the Configure Transformation Scenarios dialog you press the New button and choose "DITA OT" transformation, the dialog which shows allows you to choose Markdown or Github-flavored Markdown transformation types.
If you do not have that option on your side you are either using a custom DITA OT publishing engine (Preferences->DITA page) or you are using a very old Oxygen installation.

Regards,
Radu