docutils和Sphinx之间是什么关系? [英] What is the relationship between docutils and Sphinx?

查看:197
本文介绍了docutils和Sphinx之间是什么关系?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎有太多的Python文档工具.我遇到的另一个是epydoc. Sphinx似乎是事实上的标准,因为它用于生成正式的Python文档.有人可以帮我整理一下Python文档工具的当前状态吗?

There seems to be a plethora of documentation tools for Python. Another one that I've run across is epydoc. It seems like Sphinx is the de facto standard, because it's used to generate the official Python docs. Can someone please sort out the current state of Python's documentation tools for me?

推荐答案

epydoc Sphinx 是不同类型的工具.

epydoc and Sphinx are different types of tools.

它们的相同之处在于:

  • 两者都通过 ReST . net/"rel =" nofollow noreferrer> docutils .
  • 他们俩都非常注重Python语言
  • 两者都可以生成HTML和PDF文档
  • Both use ReST via docutils.
  • Both are very Pythonic in their focus
  • Both can generate HTML and PDF documentation

他们的重点不同.

  • Epydoc专注于API(开发人员)文档.使用Epydoc可以更快地获得更多结果.您将其指向您的源代码,您会得到一些帮助.这就是我想要的API文档工具.
  • Sphinx专注于常规(用户)文档.尽管Sphinx确实从源代码中提取了很多信息,但您需要在其中添加更多信息. Sphinx可以生成API文档,但是它不那么直接,而且IMO不能像Epydoc那样出色地工作.我知道有些人会不同意,因为Sphinx是为 Python 选择的.但是,这取决于您要投入多少工作.我喜欢Sphinx作为常规文档.
  • Epydoc is focused on API (Developer) documentation. You get more results quicker with Epydoc. You point it at your source code and you get something. This is what I want from an API documentation tool.
  • Sphinx is focused on general (User) documentation. While Sphinx does pull a lot of information from your source code you need to put a little more into it. Sphinx can generate API documentation but, it's not as straight forward, and IMO doesn't do as good of a job as Epydoc. I know some will disagree because Sphinx is chosen for Python. BUT, it depends on how much work you want to put into it. I do love Sphinx for general documentation.

因此,这取决于您要投入多少工作以及您要记录的内容.

So it depends on how much work you want to put into it and what you are documenting.

这篇关于docutils和Sphinx之间是什么关系?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆