Closed Linuus closed 11 years ago
This gem is just running the code through pygments... maybe you should file a bug against pygments instead?
Ok. I will when I get the time. I went with rouge instead. Works great.
Hello,
I'm experiencing quite the same behaviour. I have exactly the same Gemfile
and config.rb
than @Linuus, and with the following markdown code :
gem 'redcarpet'
When using Pygments online demo on Pygments website, I get the following HTML code :
<pre>
<span class="n">gem</span>
<span class="s1">'redcarpet'</span>
</pre>
But when using my middleman server and middleman-syntax, I get the following :
<pre>
<span class="n">gem</span>
<span class="err">'</span>
<span class="n">redcarpet</span>
<span class="err">'</span>
</pre>
What may go wrong ? I don't think it might be a Pygments bug, since it's working well on their online demo. Maybe we should pass some options to Pygments or something ?
@Linuus : Any tip to use Rouge in a Middleman project ?
@michaelbaudino Yes, it's very easy to implement Rouge in middleman actually. I will release a gem for it in a day or so to make it even easier :)
@Linuus Nice :-) Let me know if you need a hand, I'd be glad to help...
@michaelbaudino Here it is: https://github.com/Linuus/middleman-rouge Published on rubygems as well.
Let me know how it works for you.
@michaelbaudino
What happens when you use this markdown instead:
```ruby
gem 'redcarpet'
@bhollis Sorry, my message was not clear (I failed at embedding markdown inside markdown...) ! But that's exactly what I've been using.
In the mean time, I've tried Rouge and @Linuus' https://github.com/Linuus/middleman-rouge and it's working great.
But let me know if you need me to do any test, I can roll back to middleman-syntax, I'd be glad to help.
Hi
I just tested this gem and it works quite bad for me.
Then I use it in a .md file like this:
It seems to highlight the code pretty bad. The output can be seen here: https://gist.github.com/Linuus/5130247
It gets error on # and pretty much only n, p and o classes otherwise.
Did I do anything wrong?