prepush: show details about new remote heads with --verbose
previously, this info was only shown with --debug
Note that the new remote heads are only shown if the command aborts,
that is, they are *not* shown if --force was specified.
See also change
91cb08a9e7fb.
--- a/mercurial/discovery.py Fri Jun 03 12:16:17 2011 +0200
+++ b/mercurial/discovery.py Fri Jun 03 13:10:22 2011 +0200
@@ -173,9 +173,9 @@
else:
hint = _("did you forget to merge? "
"use push -f to force")
- repo.ui.debug("new remote heads on branch '%s'\n" % branch)
+ repo.ui.note("new remote heads on branch '%s'\n" % branch)
for h in dhs:
- repo.ui.debug("new remote head %s\n" % short(h))
+ repo.ui.note("new remote head %s\n" % short(h))
if error:
raise util.Abort(error, hint=hint)
--- a/tests/test-push-warn.t Fri Jun 03 12:16:17 2011 +0200
+++ b/tests/test-push-warn.t Fri Jun 03 13:10:22 2011 +0200
@@ -124,16 +124,22 @@
(did you forget to merge? use push -f to force)
[255]
- $ hg push -r 3 -r 4 ../c
+ $ hg push -v -r 3 -r 4 ../c
pushing to ../c
searching for changes
+ all remote heads known locally
+ new remote heads on branch 'default'
+ new remote head a5dda829a167
+ new remote head ee8fbc7a0295
abort: push creates new remote head a5dda829a167!
(did you forget to merge? use push -f to force)
[255]
- $ hg push -f -r 3 -r 4 ../c
+ $ hg push -v -f -r 3 -r 4 ../c
pushing to ../c
searching for changes
+ all remote heads known locally
+ 2 changesets found
adding changesets
adding manifests
adding file changes