md2html.awk and a question
Seumas Mac Uilleachan
seumas at idirect.ca
Thu Jul 16 21:09:23 EDT 2009
Hi, if I read your example right, the bullet markup should take priority
over anything else in that line. So the #h1 ##h2 ###h3 etc should not be
headers since they are part of a bulleted list. Also the # is not the
first character of the line.
As for the indented #an h1, should that be a header? I would think not
myself. If it's indented it's intended to be something else to my thinking.
As for the
- btw, this an h1, not a list item
===================
that is so ambiguous it could be either. I suppose the ==== and ---- headers, since they span multiple lines, probably take priority over everything.
Then again, it may depend on your markdown version (perl, php, python, haskell, etc).
yy wrote:
> Hello,
>
> I have just subscribed to this list. I will introduce myself: For some
> time, I have kept a markdown implementation in awk for personal use,
> different from other implementations. Now, I'm in the process of
> rewriting it and I'm trying to do it as compatible as possible.
>
> There are many questions I have, I know some test suites and am trying
> to pass those tests. When I don't know how to handle a corner case I
> use to check with Dingus. I would really appreciate if somebody could
> explain me the output of this text:
>
> this paragraph is outside of list blocks
>
> * #this is not a h1
> * ##this is not a h2
> * ###and this is not a h3
> * but the next one is
>
> #an h1!
> inside a list item, ok, but...
>
> * ###wtf is this?
>
> bad, bad, bad...
>
> - btw, this an h1, not a list item
> ===================
>
> - but indenting...
> ============
>
> that's better
>
> I would also like to know what is the best source for markdown syntax,
> any suggestion is welcomed. For example, I see some talk about tables
> (older versions of md2html.awk supported tables, and I hope to add
> them again). I'm slowly digging in the archives, but a reference would
> save me some time. Thanks in advance.
>
> If you are interested, you can have a look at the development process
> of md2html.awk and download the last version at
> http://www.anarchyinthetubes.com/src/md2html.awk/
>
>
>
More information about the Markdown-Discuss
mailing list