[PATCH 4 of 9] hgk: add support for phases

Matt Mackall mpm at selenic.com
Thu Nov 15 17:11:18 CST 2012


On Wed, 2012-11-07 at 21:06 +0100, Andrew Shadura wrote:
> # HG changeset patch
> # User Andrew Shadura <bugzilla at tut.by>
> # Date 1350418722 -7200
> # Node ID 3ef4e94b6ebfebbcf6fd6c295304642777f462c3
> # Parent  70544da3af3dc6619a34b309e3b944a4c4825125
> hgk: add support for phases.
> 
> Add support for phases. Update tests.

This looks fine from a technical perspective, but I'm not sure if it's
what's wanted from a UI perspective. For the most part phases are an
intentionally hidden feature in hg and you should be able to most
workflows in hg without being aware they exist (and indeed, most people
aren't aware). So I'm pretty sure we don't want to clutter the display
with "Phase: public" on the bulk of commits, though "Phase: draft" might
be more acceptable.

Pierre-David's hgview shows phases with different node colors/icons on
draft changes.

And this is a fine illustration of the advantages of uncoupling changes.
You've got a UI piece here and a backend piece. I could (very nearly)
take the backend piece right now without discussion and some forward
progress would be made. 

> +    ui.write("phase %s\n\n" % phases.phasenames[ctx.phase()])

ctx.phasestr()

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list