Hello to all! Maruku is a Markdown interpreter written in Ruby. It is released under the GPL. Maruku implements the original Markdown syntax and all the improvements in PHP Markdown Extra. Moreover, it implements some ideas from MultiMarkdown, and adds a syntax for specifying metadata for block elements. Unlike Bluecloth, Maruku creates an in-memory representation of the document tree, and this makes it very easy to export to other formats. Out of the box, Maruku offers export to HTML and to Latex/PDF. There is syntax highlighting for code blocks via the `syntax` library for HTML, and via the `listings` package for Latex. Here there are some examples: http://maruku.rubyforge.org/maruku.md http://maruku.rubyforge.org/maruku.html http://maruku.rubyforge.org/maruku.pdf http://maruku.rubyforge.org/markdown_syntax.md http://maruku.rubyforge.org/markdown_syntax.html http://maruku.rubyforge.org/markdown_syntax.pdf Download instructions at http://maruku.rubyforge.org/maruku.html#download In general it should suffice to do: $ gem install maruku This is my first time to release a gem, so let me know of any problem you encounter while installing. Try it with $ maruku file.md # converts to html $ marutex file.md # converts to tex and invokes pdflatex Any feedback is appreciated. In particular, what do you think of this (proposed) syntax for adding meta-data to span-level elements? http://maruku.rubyforge.org/maruku.html#future Have a nice day! -- Andrea Censi "Life is too important to be taken seriously" (Oscar Wilde) Web: http://www.dis.uniroma1.it/~censi
Andrea Censi <andrea at censi.org> wrote on 12/27/06 at 7:11 PM:>In particular, what do you think of this (proposed) syntax for adding >meta-data to span-level elements? > >http://maruku.rubyforge.org/maruku.html#future8.1. A syntax for specifying meta-data for span-level elements Your use of braces here is very likely to conflict with future extensions to Markdown itself. And the `@`s are very noisy, visually. 8.2. Comments. Why not just use HTML comments? --J.G.
On 12/28/06, John Gruber <gruber at fedora.net> wrote:> Andrea Censi <andrea at censi.org> wrote on 12/27/06 at 7:11 PM: > > >In particular, what do you think of this (proposed) syntax for adding > >meta-data to span-level elements? > > > >http://maruku.rubyforge.org/maruku.html#future > > 8.1. A syntax for specifying meta-data for span-level elements > > Your use of braces here is very likely to conflict with future > extensions to Markdown itself.About this, Michel Fortin referred to an old thread (2005) about meta-data syntax. I resurrected it and tried to summarize: http://maruku.rubyforge.org/markdown_extra2.html http://maruku.rubyforge.org/markdown_extra2.md Any comment after so long time?> 8.2. Comments. > > Why not just use HTML comments?For one thing, if I have to write a one-line comment: <!-- Please, Mark, have a look at the following list --> I need no less than 7 characters. Practically every language except xml allows a <delimiter> <comment> <newline> syntax. For hiding a lot of text, I concede that the <!-- --> syntax is sufficient, but is really overkill for short comments -- Andrea Censi "Life is too important to be taken seriously" (Oscar Wilde) Web: http://www.dis.uniroma1.it/~censi
Andrea Censi <andrea at censi.org> wrote on 12/27/06 at 7:11 PM:> Maruku implements the original Markdown syntax and all the > improvements in PHP Markdown Extra. Moreover, it implements some ideas > from MultiMarkdown, and adds a syntax for specifying metadata for > block elements.Maruku looks very nice overall, but I have one comment and one question. Comment: If you're going to support syntax extensions like PHP Markdown Extra's and MultiMarkdown's, you shouldn't call Maruku a Markdown interpreter. By default, "Markdown" should mean Markdown. I know there are a few features that I haven't yet officially added which almost everyone (including me) wants, especially tables. And I know it's been a long time since Markdown 1.0 shipped. But there's a huge benefit to having "Markdown", as a syntax, be as consistent as possible across implementations. Someone who knows Markdown shouldn't have to worry about "which" Markdown implementation they're using. In Maruku's case, I would prefer to see its default mode translate only the official Markdown syntax, and to handle its syntax additions as options. It's also the case that whatever the features are that will be added to the official Markdown syntax, there will be many other features that will not be added. Everyone is welcome to add their own pet features to their own implementations, but these features should not be added as though they're part of Markdown itself. The way Michel Fortin has handled this with PHP Markdown is ideal. Question: Have you benchmarked Maruku against BlueCloth? If so, how does it compare? -J.G.
* Jan Erik Mostr?m <lists at mostrom.pp.se> [2006-12-30 16:40]:> Reply to A. Pagaltzis <pagaltzis at gmx.de> 06-12-30 16:30: > >The problem is that there is effectively no spec. There is a > >format documentation, but there are many cases it does not > >specify precisely (or at all). In that case, only the > >behaviour of Markdown.pl can be of guidance; but it is not > >clear which behaviours are correct, which are incidental, and > >which are bugs; precisely because no thorough spec exists. > > I agree about the lack of a formal definition (this was > basically the reason I asked yesterday about formatters doing > "real parsing") but in my opinion this is not the main problem, > the main problem is that there are different supersets of > markdown.That doesn?t seem problematic to me. If you write documents that use features that are not part of Markdown, and the formatter documentation makes it clear that the features you are using are not part of Markdown, then you know what you are getting yourself into. I don?t see what?s bad about that. But as matters stand, you can write documents that conform to the format documentation and use no other features, and yet find that their interpretation varies among the different implementations of Markdown. This means your documents might be unwittingly tied to the specific implementation of Markdown you are using, even when they do not use any non-Markdown features. That seems actually problematic to me. Regards, -- Aristotle Pagaltzis // <http://plasmasturm.org/>