Discussed changes

John A Meinel john at arbash-meinel.com
Thu Aug 18 06:15:17 BST 2005


Martin Pool wrote:
> Suppose there are two versions of a plugin installed, one globally and
> one in the home directory.
>
> Obviously we want the users' own one to take priority.  It might cause
> trouble to load two things that both run similar initialization code,
> and I don't see why it'd be very useful.
>
> So I suggest we search a path starting with the home directory.  Once
> a name has been seen, it's not loaded again if it's found somewhere
> else.   The pattern is similar to python imports, which is good.
>
> That means you can't have plugins which override other plugins but I
> think that's fine; python modules work the same way.
>
> how's that?
>

This is closer to my proposal for the plugin path to be treated
similarly to a regular path. Things are loaded in order, and the first
one takes precedence.
Going by filename (directory name) is okay.
I don't know that it gets you a whole lot, though, because all you have
to do is change the name by a tiny bit.
So we still need to work out how "register_command" is going to work.

Since we don't currently allow multiple overloads anyway, it isn't like
we lose anything.

I would tend to say that we could load them in order, but plugins should
be aware that they could conflict, and act accordingly.

For instance, you could have multiple plugins which effectively do the
same thing, just don't have the same name.

But maybe just going by plugin name is a decent first step.

John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050818/286d02e7/attachment.pgp 


More information about the bazaar mailing list