New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

guess_lang=False doesn't work? #374

bjourne opened this Issue Nov 26, 2014 · 1 comment


None yet
2 participants

bjourne commented Nov 26, 2014

Here is my markdown file:

I want this text verbatim:

    svn co
    cd g-client

And my opts.yml:

    guess_lang: False
    GUESS_LANG: False

Converting to html:

python -m markdown -x codehilite -x meta -c opts.yml

The result is clearly syntax hilighted:

<p>I want this text verbatim:</p>
<div class="codehilite"><pre><span class="n">svn</span> <span class="n">co</span> <span     class="n">http</span><span class="o">:</span><span     class="c1">//</span>
<span class="n">cd</span> <span class="n">g</span><span class="o">-</span><span     class="n">client</span>
<span class="n">make</span>

What am I missing? Why isn't the syntax hilighting turned off for the block?


This comment has been minimized.


waylan commented Nov 26, 2014

Because 'markdown.extensions.codehilite' != 'codehilite'. Try this command instead:

python -m markdown -x markdown.extensions.codehilite -x meta -c opts.yml

The two need to match exactly. If it helps, the old way of only using the last part of an extension name only will stop working in the release after next and is discouraged. And as support for YAML config files is new, we only included support for the new requirement, but you have to use it everywhere for it to work. Perhaps that last part needs to be documented better.

@waylan waylan closed this Nov 27, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment