D7608: phabricator: color the status in the "phabstatus" view
mharbison72 (Matt Harbison)
phabricator at mercurial-scm.org
Thu Dec 12 07:52:41 EST 2019
Closed by commit rHGb0867b7751ba: phabricator: color the status in the "phabstatus" view (authored by mharbison72).
This revision was automatically updated to reflect the committed changes.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D7608?vs=18624&id=18629
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D7608/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D7608
AFFECTED FILES
hgext/phabricator.py
CHANGE DETAILS
diff --git a/hgext/phabricator.py b/hgext/phabricator.py
--- a/hgext/phabricator.py
+++ b/hgext/phabricator.py
@@ -130,6 +130,12 @@
b'phabricator.desc': b'',
b'phabricator.drev': b'bold',
b'phabricator.node': b'',
+ b'phabricator.status.abandoned': b'magenta dim',
+ b'phabricator.status.accepted': b'green bold',
+ b'phabricator.status.closed': b'green',
+ b'phabricator.status.needsreview': b'yellow',
+ b'phabricator.status.needsrevision': b'red',
+ b'phabricator.status.changesplanned': b'red',
}
_VCR_FLAGS = [
@@ -1728,7 +1734,11 @@
def phabstatus(ctx):
drev = drevsbyrev[ctx.rev()]
- ui.write(b"\n%(uri)s %(statusName)s\n" % drev)
+ status = ui.label(
+ b'%(statusName)s' % drev,
+ b'phabricator.status.%s' % _getstatusname(drev),
+ )
+ ui.write(b"\n%s %s\n" % (drev[b'uri'], status))
revs -= smartset.baseset(unknownrevs)
revdag = graphmod.dagwalker(repo, revs)
To: mharbison72, #hg-reviewers, dlax, pulkit
Cc: Kwan, mercurial-devel
More information about the Mercurial-devel
mailing list