Changes between Initial Version and Version 1 of TracMacroConfigPlugin

Nov 9, 2012, 8:00:06 PM (2 years ago)

Restored page after accidental delete.


  • TracMacroConfigPlugin

    v1 v1  
     3= Help Macros and Plugins with trac.ini lookup and defaulting =
     5== Description ==
     7''By itself, this modules does not provide any functionality.'''
     9This module provides a helper class which can be used by other plugins,
     10especially macros, in retrieving optional arguments from trac.ini.
     12A macro using this module, can be called with a '''config=xxx''' option,
     13to retrieve a set of options which in trac.ini all start with prefix '''xxx.'''
     15Inheritance is supported, by writing an option '''xxx.inherit = yyy''' in trac.ini - all macro options not yet determined, are then searched with the
     16other prefix, '''yyy.'''
     18Multiple inheritance is supported, by writing '''config=prefixA|prefixB''' in the macro invocation, or writing an '''xxx.inherit = prefixC|prefixD''' option in trac.ini
     20The macro module which uses this functionality, specifies a list of expected options, as well as their defaults. These defaults will then be used when the respective option is specified nowhere.
     22== Example ==
     24Right now, as this is brand new, no plugin / macro uses the functionality.
     26There is an '''''' file included in the distribution, which when enabled through the admin plugings interface, provides a macro named '''!TracMacroConfigExample''', which displays a table detailling various interesting things about concrete option lookups. This allows you to play with macro arguments and in a corresponding '''[macroconfig-example]''' section in trac.ini,
     27to play with inheritance setups.
     29This is how exemplary calls to that macro would be written in a wiki page:
     31[[TracMacroConfigExample(config=class-c, extra=more stuff)]]
     34Use this together with a trac.ini section like this:
     38class-a.bool = True
     39class-a.text = A Text
     40class-b.bool = False = 73
     42class-c.config = class-a|class-b
     43class-c.list = knees|toes
     46== Bugs/Feature Requests == 
     48Existing bugs and feature requests for TracMacroConfigPlugin are [report:9?COMPONENT=TracMacroConfigPlugin here].
     50If you have any issues, create a  [ new ticket].
     52== Download ==
     54Download the zipped source from [download:tracmacroconfigplugin here].
     56== Source ==
     58You can check out TracMacroConfigPlugin from [ here] using Subversion, or [source:tracmacroconfigplugin browse the source] with Trac.
     60== Recent Changes ==
     62[[ChangeLog(tracmacroconfigplugin, 3)]]
     64== Author/Contributors ==
     66'''Author:''' [wiki:bof] [[BR]]
     67'''Maintainer:''' [wiki:bof] [[BR]]
     68'''Sponsor:''' [ Yalwa Branchenbuch] [[BR]]