Jekyll Kramdown代码在有序列表中-编号重置

Jekyll Kramdown代码在有序列表中-编号重置,jekyll,liquid,github-pages,Jekyll,Liquid,Github Pages,我有以下代码,在添加液体代码块后重置编号列表: ... 6. Install the Ruby Google API client with `gem install google-api-client`, or if you prefer in a Gemfile: {% highlight ruby lineanchors %} source 'https://rubygems.org' gem 'google-api-client', '~> 0.9.1'

我有以下代码,在添加液体代码块后重置编号列表:

...
6. Install the Ruby Google API client with `gem install google-api-client`, or if you prefer in a Gemfile:
    {% highlight ruby lineanchors %}
    source 'https://rubygems.org'
    gem 'google-api-client', '~> 0.9.1'
    {% endhighlight %}
(If you've never used [Bundler](http://bundler.io) before, you should start!)

7. Let's get a quick script set up to post a Google Calendar event to...
问题是以下内容呈现为:



有序列表被重置,这显然是一个问题。我已经看过了,但是没有一个讨论过液体标签。我发现另一篇讨论这个问题的帖子毫无用处

这里是HTML输出,以备不时之需。
标签明显被液体标签引擎产生的
元素破坏。。。我不知道如何在
块中嵌入
pre

<ol>
  ...
  <li>Install the Ruby Google API client with <code>gem install google-api-client</code>, or if you prefer in a Gemfile:</li>
</ol>
<div class="highlight"><pre><code class="language-ruby" data-lang="ruby"><a name="True-1"></a><span class="n">source</span> <span class="s1">'https://rubygems.org'</span>
<a name="True-2"></a><span class="n">gem</span> <span class="s1">'google-api-client'</span><span class="p">,</span> <span class="s1">'~&gt; 0.9.1'</span></code></pre></div>
<p>(If you’ve never used <a href="http://bundler.io">Bundler</a> before, you should start!)</p>
<ol>
  <li>Let’s get a quick script set up to post a Google Calendar event to</li>
  <li>Let’s get a quick script set up to post a Google Calendar event to</li>
</ol>
(如果您以前从未使用过,应该开始使用!)

  • 让我们设置一个快速脚本,将Google日历事件发布到
  • 让我们设置一个快速脚本,将Google日历事件发布到

  • 我希望能够在不破坏
    HTML元素和重置编号的情况下,将liquid标记放入有序列表中。有什么方法可以做到这一点吗?

    对于有此问题的人,在下一个号码前添加额外的信息对我很有帮助

    6. Install the Ruby Google API client with `gem install google-api-client`, or if you prefer in a Gemfile:
        {% highlight ruby lineanchors %}
        source 'https://rubygems.org'
        gem 'google-api-client', '~> 0.9.1'
        {% endhighlight %}
    
        (If you've never used [Bundler](http://bundler.io) before, you should start!)
    
    7. Let's get a quick 
    
    正如@Joshua Meyers在评论中指出的,问题在最后一行。
    如果您缩进该行(如果您以前从未使用过,则应开始!),列表编号将继续。

    您运气不好。一些不完美的解决方法:在数字前后都留有空格吗?这个解决方案有效!不得不这么做有点烦人,但它完成了任务。谢谢你的回答!这个问题是“(如果您从未…”没有缩进。这个问题可以像这样解决:
    {:style=“list style type:none;”}100。(如果您…
    6. Install the Ruby Google API client with `gem install google-api-client`, or if you prefer in a Gemfile:
        {% highlight ruby lineanchors %}
        source 'https://rubygems.org'
        gem 'google-api-client', '~> 0.9.1'
        {% endhighlight %}
    
        (If you've never used [Bundler](http://bundler.io) before, you should start!)
    
    7. Let's get a quick