[RFC] Mercurial Queue support in qct

Steve Borho steve at borho.org
Wed Dec 27 03:08:33 UTC 2006


Hello everyone,

I've spent the bulk of the day hacking support for MQ into qct.  It works 
basically like this:

1) At startup, it runs qtop to determine if a patch is currently applied.
If no patches are applied, it runs in the usual 'commit' mode.

2) If one or more patches are applied, it makes some changes to the GUI.
 * The commit log message field is re-tasked for the patch description
 * The commit button is renamed 'Refresh'
 * Some tool-tips are updated

3) It changes the current directory to the repo root, if necessary, then runs
'hg status' to get the working directory changes and 'hg tip' to get the list 
of files currently in the top patch.  Files which are modified in the working 
directory are given 'M', 'A', 'R' annotations just like before.  Files which 
are currently in the patch but unmodified in the working directory are 
given 'm', 'a', 'r' annotations.  The 'OR' of both lists is provided to the 
user in the file list widget.  Working dir annotations are given precedence 
over patch annotations.

The user can then add and/or remove files from the top patch by toggling
them from in the file list.  The user can create/modify a description for
the patch, or they can selectively revert changes living in just the working 
directory.

This is all on the tip of my repo:  http://hg.borho.org/qct

I'm hoping to get feedback from MQ users about whether this is a useful
approach, if the feedback provided by qct is correct, and basically whether
it does 'what you expect'.

Cheers,

PS: In the future I may add more sophiscticated features like pushing/popping 
patches and re-ordering unapplied patches, but for now I'm mainly interesting 
in getting this basic operation correct.

-- 
Steve Borho (steve at borho.org)
http://www.borho.org/~steve/steve.asc
Key fingerprint = 2D08 E7CF B624 624C DE1F  E2E4 B0C2 5292 F2C6 2C8C



More information about the Mercurial-devel mailing list