[RFC] pre_commit hook

John Arbash Meinel john at arbash-meinel.com
Tue Aug 14 15:32:53 BST 2007


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

Nam Nguyen wrote:
> On 8/3/07, Robert Collins <robertc at robertcollins.net> wrote:
>> On Thu, 2007-08-02 at 11:59 -0500, John Arbash Meinel wrote:
>>> -----BEGIN PGP SIGNED MESSAGE-----
>>> Hash: SHA1
>>>
>>> Nam Nguyen wrote:
>>>> Hi list
>>>>
>>>> Please comment.
>>>>
>>>> Thanks
>>>> Nam
>>> Your new hook requests:
>>>
>>> +        # invoked before a commit operation takes place.
>>> +        # the api signature is
>>> +        # (local, master, old_revno, old_revid, future_revno, future_revid,
>>> +        #  deleted_paths, added_paths, future_revision_tree).
>>> +        # old_revid is NULL_REVISION for the first commit to a branch
>>> +        # future_revision_tree is an in-memory tree obtained from
>>> +        # CommitBuilder.revision_tree()
>>> +        # renamed paths appear in both deleted_paths and added_paths.
>>> +        self['pre_commit'] = []
>>>
>>> I would tend to:

Just a small comment. This should probably be sent as MERGE rather than RFC. Or
maybe MERGE/RFC. I realize you don't think it is ready to be merged yet (hence
RFC), but BB only tracks things marked as MERGE. So it is a bit easier to lose
track of your patches unless MERGE is in the title.

Also, your email client (gmail?) is adding the attachment as a binary
attachment, rather than a 'text + inline' attachment. This makes it a bit
harder to review, since we have to save the file and re-open it, rather than
just look at it in our email client. (Another reason to use MERGE since BB will
notice it is a bundle, and always display it).

I'm not sure how to work around this. Perhaps naming the file .txt instead of
.patch. (Or maybe '.diff'.)

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGwb0VJdeBCYSNAAMRAiBqAJ4y9jrHsBdvh0p7erq41wjnI9Tg5gCfZQyK
XWAVvxj6rNQRLAO2e6g3vQE=
=V0jk
-----END PGP SIGNATURE-----



More information about the bazaar mailing list