I was using an old code for the plugin. Now, after upgrading to redmine 2.4, and the latest code of the pygments plugin, the highlighting of c# repository files went away. I remember having this problem with the previous version as well, where I had to fix the html produced by pygments. I see the commit bab7ed9, where the html parsing is changed.
My old "fix" was like this:
result = Pygments.highlight(text, :lexer => language, :formatter => 'html', :options => options)
result.gsub!(/^<div class="highlight"><pre>/, '')
result.gsub!(/<\/pre><\/div>/, '')
result.gsub!(/^/m, '<span class="highlight">')
result.gsub!(/$/m, '</span>')
result.gsub!(/^<\/span>$/, '')
result
I'm not a ruby dev, so I don't know how to do the same with the new stuff. But replacing the new stuff with this fixed the problem for me.
I was using an old code for the plugin. Now, after upgrading to redmine 2.4, and the latest code of the pygments plugin, the highlighting of c# repository files went away. I remember having this problem with the previous version as well, where I had to fix the html produced by pygments. I see the commit bab7ed9, where the html parsing is changed.
My old "fix" was like this:
I'm not a ruby dev, so I don't know how to do the same with the new stuff. But replacing the new stuff with this fixed the problem for me.