log: do not hide the public phase in debug mode (BC)
When 51fc43253a52 introduced phases to the `hg log --debug` output, it
also disabled outputting public phase. At the same time, it always
shows phases in the default template, `hg log --debug -T default`.
Those two should produce the same output, but they don't.
I think it makes a lot more sense to always show all phases. There's
already loss of backwards compatibility in this case when using a
newer hg on an old hg repo, since draft commits will show up in the
output of `hg log --debug`.
Finally, I just don't think that any sort of information should be
hidden with --debug. This flag should be about showing as much
information as possible.
--- a/mercurial/cmdutil.py Fri Oct 03 22:03:31 2014 -0400
+++ b/mercurial/cmdutil.py Sat Oct 04 16:28:28 2014 -0400
@@ -916,7 +916,7 @@
# i18n: column positioning for "hg log"
self.ui.write(_("tag: %s\n") % tag,
label='log.tag')
- if self.ui.debugflag and ctx.phase():
+ if self.ui.debugflag:
# i18n: column positioning for "hg log"
self.ui.write(_("phase: %s\n") % _(ctx.phasestr()),
label='log.phase')
--- a/tests/test-alias.t Fri Oct 03 22:03:31 2014 -0400
+++ b/tests/test-alias.t Sat Oct 04 16:28:28 2014 -0400
@@ -208,6 +208,7 @@
$ hg dln
changeset: -1:0000000000000000000000000000000000000000
+ phase: public
parent: -1:0000000000000000000000000000000000000000
parent: -1:0000000000000000000000000000000000000000
manifest: -1:0000000000000000000000000000000000000000
--- a/tests/test-globalopts.t Fri Oct 03 22:03:31 2014 -0400
+++ b/tests/test-globalopts.t Sat Oct 04 16:28:28 2014 -0400
@@ -234,6 +234,7 @@
$ hg --cwd c log --debug
changeset: 1:b6c483daf2907ce5825c0bb50f5716226281cc1a
tag: tip
+ phase: public
parent: -1:0000000000000000000000000000000000000000
parent: -1:0000000000000000000000000000000000000000
manifest: 1:23226e7a252cacdc2d99e4fbdc3653441056de49
@@ -246,6 +247,7 @@
changeset: 0:8580ff50825a50c8f716709acdf8de0deddcd6ab
+ phase: public
parent: -1:0000000000000000000000000000000000000000
parent: -1:0000000000000000000000000000000000000000
manifest: 0:a0c8bcbbb45c63b90b70ad007bf38961f64f2af0
--- a/tests/test-phases.t Fri Oct 03 22:03:31 2014 -0400
+++ b/tests/test-phases.t Sat Oct 04 16:28:28 2014 -0400
@@ -340,6 +340,7 @@
changeset: 1:27547f69f25460a52fff66ad004e58da7ad3fb56
+ phase: public
parent: 0:4a2df7238c3b48766b5e22fafbb8a2f506ec8256
parent: -1:0000000000000000000000000000000000000000
manifest: 1:cb5cbbc1bfbf24cc34b9e8c16914e9caa2d2a7fd
@@ -352,6 +353,7 @@
changeset: 0:4a2df7238c3b48766b5e22fafbb8a2f506ec8256
+ phase: public
parent: -1:0000000000000000000000000000000000000000
parent: -1:0000000000000000000000000000000000000000
manifest: 0:007d8c9d88841325f5c6b06371b35b4e8a2b1a83