label: rename changeset.troubled into changeset.unstable
authorBoris Feld <boris.feld@octobus.net>
Thu, 03 Aug 2017 14:32:50 +0200
changeset 33781 3821dfee2cfc
parent 33780 2415ad743642
child 33782 40739aef97f7
label: rename changeset.troubled into changeset.unstable The renaming is done according to https://www.mercurial-scm.org/wiki/CEDVocabulary. Differential Revision: https://phab.mercurial-scm.org/D257
mercurial/cmdutil.py
mercurial/templates/map-cmdline.default
tests/test-obsolete.t
--- a/mercurial/cmdutil.py	Thu Aug 03 14:16:54 2017 +0200
+++ b/mercurial/cmdutil.py	Thu Aug 03 14:32:50 2017 +0200
@@ -1571,7 +1571,7 @@
     if ctx.obsolete():
         labels.append('changeset.obsolete')
     if ctx.isunstable():
-        labels.append('changeset.troubled')
+        labels.append('changeset.unstable')
         for instability in ctx.instabilities():
             labels.append('trouble.%s' % instability)
     return ' '.join(labels)
--- a/mercurial/templates/map-cmdline.default	Thu Aug 03 14:16:54 2017 +0200
+++ b/mercurial/templates/map-cmdline.default	Thu Aug 03 14:32:50 2017 +0200
@@ -29,7 +29,7 @@
 
 # General templates
 _trouble_label = 'trouble.{trouble}'
-_troubles_labels = '{if(instabilities, "changeset.troubled {instabilities%_trouble_label}")}'
+_troubles_labels = '{if(instabilities, "changeset.unstable {instabilities%_trouble_label}")}'
 _obsolete_label = '{if(obsolete, "changeset.obsolete")}'
 _cset_labels = '{separate(" ", "log.changeset", "changeset.{phase}", "{_obsolete_label}", "{_troubles_labels}")}'
 cset = '{label("{_cset_labels}",
--- a/tests/test-obsolete.t	Thu Aug 03 14:16:54 2017 +0200
+++ b/tests/test-obsolete.t	Thu Aug 03 14:32:50 2017 +0200
@@ -948,7 +948,7 @@
 test the obsolete labels
 
   $ hg log --config ui.logtemplate= --color=debug -r 'phasedivergent()'
-  [log.changeset changeset.draft changeset.troubled trouble.orphan trouble.phase-divergent|changeset:   7:50c51b361e60]
+  [log.changeset changeset.draft changeset.unstable trouble.orphan trouble.phase-divergent|changeset:   7:50c51b361e60]
   [log.user|user:        test]
   [log.date|date:        Thu Jan 01 00:00:00 1970 +0000]
   [log.trouble|instability: orphan, phase-divergent]
@@ -956,7 +956,7 @@
   
 
   $ hg log -T default -r 'phasedivergent()' --color=debug
-  [log.changeset changeset.draft changeset.troubled trouble.orphantrouble.phase-divergent|changeset:   7:50c51b361e60]
+  [log.changeset changeset.draft changeset.unstable trouble.orphantrouble.phase-divergent|changeset:   7:50c51b361e60]
   [log.user|user:        test]
   [log.date|date:        Thu Jan 01 00:00:00 1970 +0000]
   [log.trouble|instability: orphan, phase-divergent]