sunaku / md2man

📚 Converts markdown into UNIX manual pages
https://sunaku.github.io/md2man/man
Other
374 stars 23 forks source link

Support for definition lists #20

Closed mavam closed 9 years ago

mavam commented 9 years ago

Does support for description lists exist for roff output? I tried the markdown extra syntax but did not see an effect. I'd be nice to have that feature, as it is available in ronn.

sunaku commented 9 years ago

Tagged paragraphs are the closest things to definition lists that md2man currently offers.

mavam commented 9 years ago

I see. One question regarding the output generation: is the following expected behavior?

The markdown code

`foo`
   f
   fo
   foo

  `bar` 
   b
   ba
   bar

`baz`
 b
 ba
 baz

yields a man page of the form

       foo
          f
          fo
          foo

       bar       b
                 ba
                 bar

       baz b ba baz

and in roff:

\fB\fCfoo\fR
   f
   fo
   foo
.TP
\fB\fCbar\fR 
   b
   ba
   bar
.PP
\fB\fCbaz\fR
b
ba
baz
sunaku commented 9 years ago

Yes, that is as expected. :+1: Your first and second paragraphs are tagged paragraphs, which are most similar to the definition lists you seek. In contrast, your third paragraph is a normal paragraph. :necktie:

mavam commented 9 years ago

Okay, perfect. This is close enough to definition lists. I'll close the ticket for now.