遇到的问题是这样的。我在本地用Jekyll
新建了一个Blog
,写好一篇post
后发布到Git
托管的Page
上。在互联网上访问文章页面,就会发现是这个样子的:
显然,这里面有一些Markdown
格式没有被正确解析成HTML
,在下面给出的地址中可以看到更多错误。我尝试把同样的内容发布在Github
上,结果是一样的。我在本地发布(# jekyll serve
),就会发现内容格式解析正确,但会有如下提示:
Generating... Maruku#to_s is deprecated and will be removed or changed in a near-future version of Maruku.
图中的文章在这里,这份提交的post
在这里,另一篇跟图中文章格式类似的测试帖在这里。
并不指望能在社区直接找到解决方案,但求提供解决问题的思路,我会顺着可行的思路寻找答案。有兴趣的小伙伴可一起尝试解决。
阿神2017-04-24 09:14:19
Maybe your git markdown parser is different from your local one, resulting in some syntax incompatibility
黄舟2017-04-24 09:14:19
Difference issue in markdown parser. It is strongly recommended to build a local environment of github pages to preview. For the construction method, see: https://help.github.com/articles/using-jekyll-with-pages.
Note: Never use the official jekyll engine (http://jekyllrb.com/) to generate static html. You must use your own engine from github pages:
bundle exec jekyll serve
. Because there is a big difference in syntax between the jekyll used by github pages and the official jekyll - this will cause the official jekyll test to take effect, but it will not take effect after being pushed to github pages.
To avoid the local github-pages engine version being too old or some potential bugs, please remember to update in time: bundle update