I'm currently attempting to write a spec for parsing Markdown Extra, and since one goal is to minimize the differences in output between implementations, I've made a tool allowing me to compare who does what for any given input. I hope this can also facilitate future discussions about the syntax. So here's Babelmark, a testbed for various Markdown implementations were you give the input and you get the HTML output for Markdown.pl 1.0.1 and 1.0.2b8, PHP Markdown and PHP Markdown Extra, Python Markdown, Text::Markdown and Text::MultiMarkdown, and finally Showdown. Unfortunatly, my web host doesn't do Ruby, nor Java, C# or Lua, so the online version is missing a couple of interesting implementations. Locally on my computer Babelmark also do BlueCloth, Maruku, MarkdownJ, markdown.lua, and Pandoc. I'm very sorry if your Markdown implementation can't be part of Babelmark online, but if anyone has a better host to offer for Babelmark, ideally with support for all of these, I'd gladly send him the scripts. You can find Babelmark here: <http://michelf.com/projects/babelmark/> Also note that, contrary to the normal Markdown or PHP Markdown dingus, you can bookmark specific tests since the input string is encoded in the URI. Here are some interesting cases for instance: <http://michelf.com/projects/babelmark/?markdown=_test_test_test_> <http://michelf.com/projects/babelmark/?markdown=*test+%5Btest*+test%5D%28%23%29 > <http://michelf.com/projects/babelmark/?markdown=%5Btest%5D%0D%0A%0D%0A%5Btest%5D%3A+%23 > So that's it. Have fun with it. Michel Fortin michel.fortin at michelf.com http://michelf.com/
This is a great tool. It won't solve all of our problems by itself (we still need a spec), but I think it will help a great deal if we want to try to bring all the implementations into agreement. Some of my tests that show interesting differences: <%foo ok %>: http://michelf.com/projects/babelmark/?markdown=%3C%25foo+ok+%25%3E (BTW, where does one get Markdown.pl 1.0.2 beta? Markdown website says that the last version is 1.0.1, of 2004.) foo_bar_bas: http://michelf.com/projects/babelmark/?markdown=foo_bar_bas 2-tier list indented by three spaces: http://michelf.com/projects/babelmark/?markdown=*+what%27s+up%3F%0D%0A+++*+ok Now, on this one, I must say I have mixed feelings, since python-markdown is the only implementation that follows "Markdown Syntax" and treats the item indented by three spaces as being at the same level. Makes me feel like a naive fool for following the "spec". :) One more thing: python-markdown is a stickler for explicit encoding (because we rely on it for bidi-detection). The input must be either python Unicode object or UTF8 encoded byte-string or you must say what encoding you are using. Your test doesn't seems to send something other than UTF8 without specifying encoding. http://michelf.com/projects/babelmark/?markdown=_%D8%A7%D9%84%D9%92%D8%B9%D9%8E%D8%B1%D9%8E%D8%A8%D9%8A%D9%91%D8%A9_+ Should we start a page on the wiki to collect those examples so that we can then discuss what ought to be done in each case? - yuri On Sat, Mar 22, 2008 at 10:09 AM, Michel Fortin <michel.fortin at michelf.com> wrote:> I'm currently attempting to write a spec for parsing Markdown Extra, > and since one goal is to minimize the differences in output between > implementations, I've made a tool allowing me to compare who does what > for any given input. I hope this can also facilitate future > discussions about the syntax.-- http://sputnik.freewisdom.org/
* Yuri Takhteyev <qaramazov at gmail.com> [2008-03-22 19:00]:> (BTW, where does one get Markdown.pl 1.0.2 beta? Markdown > website says that the last version is 1.0.1, of 2004.)http://daringfireball.net/projects/downloads/Markdown_1.0.2b8.tbz Regards, -- Aristotle Pagaltzis // <http://plasmasturm.org/>
Any reason for including Text::MultiMarkdown and not the official MultiMarkdown itself? It would be useful for finding any areas where the two versions differ from each other, in addition to where MMD differs from other implementations. This looks like a fantastic tool, in either case - thanks for sharing it. F- On Mar 22, 2008, at 1:09 PM, Michel Fortin wrote:> I'm currently attempting to write a spec for parsing Markdown Extra, > and since one goal is to minimize the differences in output between > implementations, I've made a tool allowing me to compare who does > what for any given input. I hope this can also facilitate future > discussions about the syntax. > > So here's Babelmark, a testbed for various Markdown implementations > were you give the input and you get the HTML output for Markdown.pl > 1.0.1 and 1.0.2b8, PHP Markdown and PHP Markdown Extra, Python > Markdown, Text::Markdown and Text::MultiMarkdown, and finally > Showdown. > > Unfortunatly, my web host doesn't do Ruby, nor Java, C# or Lua, so > the online version is missing a couple of interesting > implementations. Locally on my computer Babelmark also do BlueCloth, > Maruku, MarkdownJ, markdown.lua, and Pandoc. I'm very sorry if your > Markdown implementation can't be part of Babelmark online, but if > anyone has a better host to offer for Babelmark, ideally with > support for all of these, I'd gladly send him the scripts. > > You can find Babelmark here: > > <http://michelf.com/projects/babelmark/> > > Also note that, contrary to the normal Markdown or PHP Markdown > dingus, you can bookmark specific tests since the input string is > encoded in the URI. Here are some interesting cases for instance: > > <http://michelf.com/projects/babelmark/?markdown=_test_test_test_> > <http://michelf.com/projects/babelmark/?markdown=*test+%5Btest*+test%5D%28%23%29 > > > <http://michelf.com/projects/babelmark/?markdown=%5Btest%5D%0D%0A%0D%0A%5Btest%5D%3A+%23 > > > > So that's it. Have fun with it. > > > Michel Fortin > michel.fortin at michelf.com > http://michelf.com/ > > > _______________________________________________ > Markdown-Discuss mailing list > Markdown-Discuss at six.pairlist.net > http://six.pairlist.net/mailman/listinfo/markdown-discuss-- Fletcher T. Penney fletcher at fletcherpenney.net I had just received my degree in Calcium Anthropology...the study of milkmen. - Steven Wright -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 2437 bytes Desc: not available Url : <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20080322/b3514fe3/attachment-0001.bin>
On 22 Mar 2008, at 17:09, Michel Fortin wrote:> I'm currently attempting to write a spec for parsing Markdown > Extra, and since one goal is to minimize the differences in output > between implementations, I've made a tool allowing me to compare > who does what for any given input. I hope this can also facilitate > future discussions about the syntax. > > So here's Babelmark, a testbed for various Markdown implementations > were you give the input and you get the HTML output for Markdown.pl > 1.0.1 and 1.0.2b8, PHP Markdown and PHP Markdown Extra, Python > Markdown, Text::Markdown and Text::MultiMarkdown, and finally > Showdown. >This is really totally awesome :)> Unfortunatly, my web host doesn't do Ruby, nor Java, C# or Lua, so > the online version is missing a couple of interesting > implementations. Locally on my computer Babelmark also do > BlueCloth, Maruku, MarkdownJ, markdown.lua, and Pandoc. I'm very > sorry if your Markdown implementation can't be part of Babelmark > online, but if anyone has a better host to offer for Babelmark, > ideally with support for all of these, I'd gladly send him the > scripts. >I should be able to do all (or at least most of) the above, can I get a copy of the code (or access to the source control where it's located?). It would be interesting to be able to track 'should be like' implementations (for me, especially) - what would be good is some system that emailed me 'aggh' emails every time someone typed something and Text::Markdown was different to Markdown.pl.. However that would be trivially easy to spam me with, so might need some careful thought. ;) Cheers Tom
On Sun, Mar 23, 2008 at 5:44 AM, Fletcher T. Penney <fletcher at fletcherpenney.net> wrote:> One problem with babelmark - the CSS is such that a long line of > output (or input) forces the body off the left side of the page. > > > For an example, try the following text in the babelmark text source: > > Test footnote.[^1][]. > > [^1]: This is a footnote.or this: http://michelf.com/projects/babelmark/?markdown=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
> Unfortunatly, my web host doesn't do Ruby, nor Java, C# or Lua, so the > online version is missing a couple of interesting implementations.If your host allows you to ssh and has make, then building Lua is very simple: mkdir ~/lua # or some other directory wget http://sputnik.freewisdom.org/files/easy-lua-install-2007-01-18 bash easy-lua-install-2007-01-18 --without-readline --prefix=/home/yuri/lua/ cd share/lua/5.1/ wget www.frykholm.se/files/markdown.lua ~/lua/bin/lua This will get you the interactive prompt: Lua 5.1.2 Copyright (C) 1994-2007 Lua.org, PUC-Rio> require"markdown" > =markdown("oh _hai_")<p>oh <em>hai</em></p>> Locally on my computer Babelmark also do BlueCloth, Maruku, MarkdownJ, > markdown.lua, and Pandoc. I'm very sorry if your Markdown > implementation can't be part of Babelmark online, but if anyone has a > better host to offer for Babelmark, ideally with support for all of > these, I'd gladly send him the scripts.I can try and see how far I get on webfaction. Can you send me the scripts? - yuri -- http://sputnik.freewisdom.org/
On Mar 24, 2008, at 4:47 PM, John MacFarlane wrote:> Here are some of my personal favorites, with lots of divergence > between implementations:Here is another funny one: http://babelmark.bobtfish.net/?markdown=_M*A*S*H_&normalize=on Great resource :) -- PA. http://alt.textdrive.com/nanoki/