15
17

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

SphinxでMarkdownを使うときに注意すること

Posted at

SphinxでMarkdownを使うときにつまずいた。

参考にしたページ

  1. http://blog.readthedocs.com/adding-markdown-support/
  2. https://github.com/rtfd/recommonmark/issues/24

問題

私の場合、下記のような状況でした。2.を読んでみるとversionがあっていなかったので、versionを合わしてあげたら実行できるようになりました。


from recommonmark.parser import CommonMarkParser
....
ImportError: cannot import name DocParser

やった事

$ pip install recommonmark==0.4.0

Sphinxプロジェクトのconf.pyの中を編集

from recommonmark.parser import CommonMarkParser

source_parsers = {'.md': CommonMarkParser}

source_suffix = ['.rst', '.md']
15
17
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
15
17

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?