Changes between Version 24 and Version 25 of PyDocPlugin
- Timestamp:
- Mar 18, 2015, 9:41:30 AM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
PyDocPlugin
v24 v25 1 [[PageOutline ]]1 [[PageOutline(2-5,Contents,pullout)]] 2 2 3 = Python documentation plugin =3 = Python documentation plugin 4 4 5 == Description ==5 == Description 6 6 7 This plugin allows the user to browse Python documentation through Trac's interface, 8 using the `pydoc` documentation system. 7 This plugin allows the user to browse Python documentation through Trac's interface, using the `pydoc` documentation system. 9 8 10 It was originally written for Trac 0.9, but there's now a fully 0.10 compatible version, 11 and even a Genshi version for Trac 0.11dev. 9 It was originally written for Trac 0.9, but there's now a fully 0.10 compatible version, and even a Genshi version for Trac 0.11dev. 12 10 13 == Alternatives to `pydoc` ==11 == Alternatives to `pydoc` 14 12 15 Tools that use static code analysis would be much more preferable to those that 16 compile the Python code and inspect the doc strings. Some tools that do this 17 are [https://svn.enthought.com/enthought/wiki/EndoHowTo Endo] (promising), [http://effbot.org/zone/pythondoc.htm PythonDoc] (promising), [http://happydoc.sourceforge.net/ Happy Doc] and 18 [http://codespeak.net/svn/user/mwh/pydoctor/trunk/ PyDoctor] (requires trunk version of some divmod modules, couldn't get it working). 13 Tools that use static code analysis would be much more preferable to those that compile the Python code and inspect the doc strings. Some tools that do this are [https://svn.enthought.com/enthought/wiki/EndoHowTo Endo] (promising), [http://effbot.org/zone/pythondoc.htm PythonDoc] (promising), [http://happydoc.sourceforge.net/ Happy Doc] and [http://codespeak.net/svn/user/mwh/pydoctor/trunk/ PyDoctor] (requires trunk version of some divmod modules, couldn't get it working). 19 14 20 Others are [http://pudge.lesscode.org/ Pudge] and [http://epydoc.sourceforge.net/ EpyDoc]. 21 [http://epydoc.sourceforge.net/ EpyDoc] is fully supported by EpyDocPlugin. 15 Others are [http://pudge.lesscode.org/ Pudge] and [http://epydoc.sourceforge.net/ EpyDoc]. [http://epydoc.sourceforge.net/ EpyDoc] is fully supported by EpyDocPlugin. 22 16 23 == Usage ==17 == Bugs/Feature Requests 24 18 25 === Wiki Links === 19 Existing bugs and feature requests for PyDocPlugin are 20 [report:9?COMPONENT=PyDocPlugin here]. 21 22 If you have any issues, create a 23 [http://trac-hacks.org/newticket?component=PyDocPlugin&owner=athomas new ticket]. 24 25 [[TicketQuery(component=PyDocPlugin&group=type,format=progress)]] 26 27 == Download 28 29 Download the zipped source corresponding to your Trac version: 30 || Trac 0.9 || [download:pydocplugin/0.9 pydocplugin/0.9] || 31 || Trac 0.10 || [download:pydocplugin/0.10 pydocplugin/0.10] || 32 || Trac 0.11 || [download:pydocplugin/0.11 pydocplugin/0.11] || 33 34 == Source 35 36 You can check out PyDocPlugin from [http://trac-hacks.org/svn/pydocplugin here] using Subversion, or [source:pydocplugin browse the source] with Trac. 37 38 == Usage 39 40 === Wiki Links 26 41 27 42 Use `pydoc:object` to link to the documentation for `object`. 28 43 29 === Inline Expansion of Python Documentation ===44 === Inline Expansion of Python Documentation 30 45 31 46 The `[[pydoc(target[,visibility])]]` macro will expand the documentation for `object` inline. 32 47 33 `visibility` can be either `public`, `private` or left empty, in which case the visibility 34 depends on the [pydoc] show_private setting. 48 `visibility` can be either `public`, `private` or left empty, in which case the visibility depends on the [pydoc] show_private setting. 35 49 36 === Searching the Python Documentation ===50 === Searching the Python Documentation 37 51 38 52 Documentation searches use the same mechansim as `pydoc -k`. Not ideal, but sufficient. 39 53 40 == Configuration ==54 == Configuration 41 55 42 56 All configuration occurs under the [pydoc] section of `trac.ini`. 43 57 44 === Documentation Search Path ===58 === Documentation Search Path 45 59 46 The Python documentation will only be displayed for builtin modules and for 47 the modules listed in the `sys.path` configuration option (use the `os.pathsep` 48 character in order to separate the paths). 60 The Python documentation will only be displayed for builtin modules and for the modules listed in the `sys.path` configuration option. Use the `os.pathsep` character in order to separate the paths. 49 61 50 If the configuration key is not set, the `sys.path` variable value will be 51 used. 62 If the configuration key is not set, the `sys.path` variable value will be used. 52 63 53 64 In addition, the index can also be filtered through an include/exclude list. 54 This is a glob, so you will need appropriate wildcards to match correctly. 55 For example, to display all DBM modules except anydbm: 65 This is a glob, so you will need appropriate wildcards to match correctly. For example, to display all DBM modules except anydbm: 56 66 57 67 {{{ 68 #!ini 58 69 [pydoc] 59 70 include = *dbm* … … 64 75 65 76 {{{ 77 #!ini 66 78 [pydoc] 67 79 include = trac trac.* … … 70 82 '''Note:''' You will need both `trac` and `trac.*` as browsing matches against the module name and searching matches against the full object name. 71 83 72 === Display Private Documentation ===84 === Display Private Documentation 73 85 74 86 Added `show_private` configuration setting for `[pydoc]`. 75 76 The Python private documentation can now be displayed for the modules 77 that are found in this space separated list of module patterns. 78 79 e.g. in order to show the private documentation for Trac and the WebAdmin plugin: 87 The Python private documentation can now be displayed for the modules that are found in this space separated list of module patterns. For example, in order to show the private documentation for Trac and the WebAdmin plugin: 80 88 81 89 {{{ 90 #!ini 82 91 [pydoc] 83 92 show_private = trac.* webadmin.* 84 93 }}} 85 94 86 == Bugs/Feature Requests == 87 88 Existing bugs and feature requests for PyDocPlugin are 89 [report:9?COMPONENT=PyDocPlugin here]. 90 91 If you have any issues, create a 92 [http://trac-hacks.org/newticket?component=PyDocPlugin&owner=athomas new ticket]. 93 94 == Download == 95 96 Download the zipped source corresponding to your Trac version: 97 || Trac 0.9 || [download:pydocplugin/0.9 pydocplugin/0.9] || 98 || Trac 0.10 || [download:pydocplugin/0.10 pydocplugin/0.10] || 99 || Trac 0.11 || [download:pydocplugin/0.11 pydocplugin/0.11] || 100 101 == Source == 102 103 You can check out PyDocPlugin from [http://trac-hacks.org/svn/pydocplugin here] using Subversion, or [source:pydocplugin browse the source] with Trac. 104 105 == Example == 95 == Example 106 96 107 97 Use `pydoc:trac` to view the Python documentation for Trac. … … 109 99 Use `[[pydoc(os.path.isdir)]]` to inline the documentation for `os.path.isdir()`. 110 100 111 == Author/Contributors == 101 == Recent Changes 102 103 [[ChangeLog(pydocplugin, 3)]] 104 105 == Author/Contributors 112 106 113 107 '''Author:''' [wiki:athomas] [[BR]] 114 '''Contributors:''' [wiki:cboos] [[BR]] 115 116 [[TagIt(plugin,athomas,0.9,0.10,cboos)]] 108 '''Contributors:''' [[Maintainer]] [[BR]] 109 '''Authors:''' [wiki:athomas] [wiki:cboos][[BR]] 117 110 118 111