Use color on 'status' and 'qseries' output

TK Soh teekaysoh at gmail.com
Thu Dec 27 19:03:47 CST 2007


On Dec 28, 2007 12:26 AM, Kevin Christen <kevin.christen at gmail.com> wrote:
> I've put together the attached patch to use different colors for different
> file statuses on the 'status' command, and to differentiate between applied
> and unapplied patches on the 'qseries' command.  I implemented this as
> changes to the existing commands rather than extensions because:
>
> Extensions would have required copy and pasting large chunks of
> mercurial.hg.status and hgext.mq.queue.qseries, and I hate cut and paste
> coding.
> Parallel command sets don't seem like a very good idea as the number of
> commands grows ('diff' and 'cdiff', 'status' and 'cstatus', 'qseries' and
> 'cqseries', ...) I'd appreciate feedback on these (and any other) questions:
>
> Do you find this useful?
> What other commands might benefit from this treatment?
> Has any thought been given to changing the alias extension to allow aliasing
> of built-in commands (alias diff=cdiff).  That would address the issue of
> parallel command sets.
> How's my python?  I'm fairly new to the language.Thanks,
> Kevin Christen

I like the idea. Though I would prefer --color option over --no-color
option. I use Hg mainly on legacy *nix system without colored
terminals.

Maybe this should be available as an extension?


More information about the Mercurial-devel mailing list