Changes between Version 6 and Version 7 of TracPlugins
- Timestamp:
- Sep 8, 2024, 12:14:12 PM (3 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracPlugins
v6 v7 7 7 == Plugin discovery 8 8 9 A plugin is either a single .py file or a package (.egg or .whl). Trac looks for plugins in Python's `site-packages` directory, the [TracIni#GlobalConfiguration global shared] `plugins` directory and the [TracEnvironment project environment] `plugins` directory. Plugins installed to the project environment `plugins` directory are enabled, unless explicitly disabled in the `[components]` section of the `trac.ini` file. Plugins installed elsewhere must be explicitly enabled in the [TracIni#components-section "[components]"] section of the `trac.ini` file.9 From the user's point of view, a plugin is either a single .py file or a package (.egg or .whl). Trac looks for plugins in Python's `site-packages` directory, the [TracIni#GlobalConfiguration global shared] `plugins` directory and the [TracEnvironment project environment] `plugins` directory. Plugins installed to the project environment `plugins` directory are enabled, unless explicitly disabled in the `[components]` section of the `trac.ini` file. Plugins installed elsewhere must be explicitly enabled in the [[TracIni#components-section| [components] ]] section of the `trac.ini` file. 10 10 11 11 == Installing a Trac plugin … … 15 15 === For a single project 16 16 17 Packages built for a single project must use the egg format, as the wheel format (described below) is not supported by the setuptools loading mechanism. Build the `egg` file from the plugin source: 17 Packages built for a single project must use the egg 18 format, as the wheel format (described below) is not 19 supported by the setuptools loading mechanism. Build the `egg` file from the plugin source: 18 20 19 21 * Checkout or download and unpack the source. 20 * Change to the directory containing `setup.py` and run: 22 * Change to the directory containing `setup.py`. 23 * Run: 21 24 {{{#!sh 22 25 $ python setup.py bdist_egg … … 49 52 ==== From PyPI 50 53 51 Some plugins, such as [ https://trac-hacks.org/wiki/TagsPlugin TracTags], can be installed directly from [https://pypi.org PyPI] using `pip`:54 Some plugins, such as [th:TagsPlugin TracTags], can be installed directly from [https://pypi.org PyPI] using `pip`: 52 55 {{{#!sh 53 56 $ pip install TracTags