I use Markdown with Liquid tags to mark up the code for a site created by Jekyll, and would like to include some code that is both inline (in the paragraph) and color syntax (using Pygments), but it does not work.
Markup
Lorem ipsum dolor {% highlight javascript %} var sit = "amet"; {% endhighlight %} consectetur adipiscing elit.
leads to
<p>Lorem ipsum dolor <div class='highlight'><pre><code class='javascript'> <span class='kd'>var</span> <span class='nx'>sit</span> <span class='o'>=</span> <span class='s2'>"amet"</span><span class='p'>;</span></code></pre></div> consectetur adipiscing elit.</p>
I would really like the selected text not to be wrapped in <div class='highlight'> , or at least it was <span class='highlight'> .
Using {% highlight javascript nowrap %} does not work, as elsewhere . (Perhaps this is a problem with my setup - Ruby 2.0, Jekyll 0.12.1, pygments.rb 0.3.7?)
I would like to host this page on GitHub , which means that I cannot rely on the plugin. Bummer, right?
Addendum: Line numbering (ie {% highlight javascript linenos %} ) does not work either. Man.
lucasrizoli
source share