[PATCH] Add support for external command handlers

Aaron Bentley aaron.bentley at utoronto.ca
Sat May 7 10:16:41 BST 2005


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

Hi Michael,

Michael Ellerman wrote:
> Hi Martin,
> 
> This patch allows you to create a script, eg. 'do-cool-stuff' which you place
> somewhere in your BZRPATH. Then when you type 'bzr do-cool-stuff' bzr will
> find the script and call it.

This reminds me of my aba tla wrapper and Fai Arch front-end.
(http://push.sourcecontrol.net/~abentley/aba.php)  Both use the same
conventions to allow external scripts/executables and tla commands to be
used interchangeably.

foo exec $*	Perform their operation on the supplied arguments
foo exec (-h|--help)	Provide short help
foo exec (-H)	Provide long help
foo desc	Describe the script's function, in 'tla help' format

All the options except -H would apply to bzr, too.

I should note though, that what I was doing with Fai was treating Tom
Lord as 'damage' wrt usability, and routing around him.  With Martin, I
don't think that's necessary, so Python scripts might be best, as they
allow him to integrate them into the core as appropriate.

Fai also had a plugin system for Python commands-- I'd be happy to
contribute it.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCfId50F+nu1YWqI0RAtYBAJ9dM5e62ZuR+TXrhwoxyMK0myQtwACcCWGm
Rqi2nkBcD4IPWOPP+Y4i3+E=
=e9jL
-----END PGP SIGNATURE-----




More information about the bazaar mailing list