WorkingTree.wt.get_config_stack and BzrDirConfig

Jelmer Vernooij jelmer at samba.org
Fri Feb 3 12:55:42 UTC 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Aaron,

On 02/02/2012 09:21 PM, Aaron Bentley wrote:
> I've actually just started getting familiar with config stacks this
> week, fixing a bug in bzr-pqm caused by the cutover.
>
> I see that you've added a way of getting a config from a WorkingTree,
> with hints that per-working-tree configs might be supported in the future.
>
> I think it's worth considering using the per-bzrdir config for this,
> rather than implementing something that only works for working trees.
>
> The BzrDirConfig is pretty obscure right now, because we only use it
> to configure the default stacking location. We needed a way to
> configure a location that allowed remote configuration (so
> locations.conf and bazaar.conf were out), but that location could have
> no branch or repository (so branch.conf was out).
>
> But it would be possible to use it for branches, trees and
> repositories, too, since they all have control directories. And I
> think that collecting all that configuration in one place would be a
> nice simplification.
>
> The only thing is that this is a behaviour change, so it could require
> format changes. But adding a per-working-tree config would also be a
> behaviour change.
Yeah, we need to figure out what the right location is. I agree adding
more configuration files isn't really the answer.

Using the BzrDir config might be appropriate, although it's kind of odd
that it's in control.conf. That name suggests that it's specific to the
control directory, and not shared across everything that lives there
(including the working tree and branches).

Living with a slightly awkward name might be a better alternative than
actually adding a new file though.

Cheers,

Jelmer
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJPK9lOAAoJEACAbyvXKaRXBlEP/0NUi3A8ewxkrrxELpwOsTzt
E1m7VT2NMG4TBzd75+BYEjBGLczam9q5SlftnMOM2+3b/FTc4JO+Vrc/sbkSc6uz
gKDKSLhU0eRJCOHf0E2CkE7nkiZG19vhC9TfBQBQc1MUymjI95qmflnFZ3MuyfGk
jGacyZ3YaO/g7uzKFSWUE0hnlgJFIsCrFlKlboCYIvgirKfkNxiiCl7AWBxJILCm
u65IZw89CxnTMRyuCL/yS7U3l13Xxx92Srwx4QLHZzQekqAhRPFsvXLIFeENeXGD
VATMp6Q3PryCuVQ0vnDENJhn2FxwOuT/pFJY1f/fi0CVw7J5Ficq8Ds6Fx1evT/n
WN2ASM1YedQg4E/O2PQiBA8t8ccO5MRgBRcUrvZMkHBZwFfwTdS2qr3rLGv4R0RV
I90e0y+b6ZLhJsW3vQX7lfMYN/sCk4K0g792fVJ0aT9EaeOZn4R602KJ98PKZ7Nt
GKAm5HuXPoSkwg+yy95Ihqqs+LA0R5n4iGtqOWBlEpK0rycNoD33g8Mrm74pVDHS
RYAvcP/IzPuharH1c9dMRG0jqC+CZLG9LvnhwOL6OV33f4Rk6U/MYDVq8rGyKjTA
gwfn/EIn5K1o7jlyvZzF4L5D1dl/7AMMqSJVxGHX3Xvy1VxlXjKyP2SZ90oQLjYk
I9tzAq4eeQLZhGeVnSFg
=UP1t
-----END PGP SIGNATURE-----




More information about the bazaar mailing list