/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to doc/developers/configuration.txt

  • Committer: Jelmer Vernooij
  • Date: 2017-05-21 18:10:28 UTC
  • mto: This revision was merged to the branch mainline in revision 6623.
  • Revision ID: jelmer@jelmer.uk-20170521181028-zn04pdfw0od9hfj3
Rename brzlib => breezy.

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
----------------
32
32
 
33
33
You add a new ``Option`` to the ``option_registry``, either inside
34
 
``brzlib/config.py`` or during initialization of your plugin (use
 
34
``breezy/config.py`` or during initialization of your plugin (use
35
35
``register_lazy`` in this case). New plugins should have systematic
36
36
hierarchical names so that related values are grouped together::
37
37
 
310
310
Specific section matchers can be implemented by overriding ``get_sections``
311
311
or just ``match``.
312
312
 
313
 
``brzlib`` provides:
 
313
``breezy`` provides:
314
314
 
315
315
* ``NameMatcher(store, unique_id)``: To select a single section matching
316
316
  ``unique_id``.
326
326
 
327
327
An option can take different values depending on the context it is
328
328
used. This can involve configuration files, options from the command line,
329
 
default values in brzlib and then some.
 
329
default values in breezy and then some.
330
330
 
331
331
Such a context is implemented by creating a list of ``Section`` stacked upon
332
332
each other. A ``Stack`` can then be asked for an option value and returns the
361
361
allows for simpler and faster tests. A common pattern is to accept a
362
362
``config`` parameter related to a given feature and test it with predefined
363
363
configurations without involving the whole
364
 
stack. ``brzlib.tests.test_commit``, ``brzlib.tests.test_gpg`` and
365
 
``brzlib.tests.test_smtp_connection`` are good examples.
 
364
stack. ``breezy.tests.test_commit``, ``breezy.tests.test_gpg`` and
 
365
``breezy.tests.test_smtp_connection`` are good examples.
366
366