[RFC] Changing the generate_commit_message_template and commit_message_template hook APIs

John Szakmeister john at szakmeister.net
Mon Sep 14 12:45:50 BST 2009


On 9/13/09, Martin Pool <mbp at canonical.com> wrote:
[snip]
> Those are good cases to keep in mind, but I don't think it's
> inherently unreasonable to say "do a dry-run commit and give me the
> template", then later "actually commit, using this message."
> Obviously there is some risk of the tree changing in the interim but I
> can imagine people liking to use it from shell scripts or emacs or
> other things.  It is a bit inefficient too.
>
> Another (maybe weird) approach is to have the in-process commit editor
> be: write the template to a tmp file, then connect to this named pipe
> and read the message back from there.  That gives you a handoff to an
> asynchronous process: it gets the template, does its thing, and when
> the user presses ok opens that pipe and writes.  This will vary a bit
> between unix and Windows but in principle (heh) it should work
> everywhere.

Does attempting to get the message in the middle of the commit prevent
things like diff from working?  One of the really nice features of
qcommit is the ability to view the files being committed and write an
appropriate log message, as well as filter off any files I don't want
committed yet.  Preventing those features from working would be a real
detriment to QBzr, IMHO.

-John



More information about the bazaar mailing list