[PATCH 4 of 4 V2] largefiles: don't print largefile changes in updaterepo() without regular stats

Matt Harbison matt_harbison at yahoo.com
Sun Jan 6 16:16:41 CST 2013


# HG changeset patch
# User Matt Harbison <matt_harbison at yahoo.com>
# Date 1357504524 18000
# Node ID e0a36600a4b62df52004337736409469a4700d3b
# Parent  3e9e34fd72948c311e032778c75a9fab2bb5d399
largefiles: don't print largefile changes in updaterepo() without regular stats

This eliminates standalone "getting largefiles" messages when the corresponding
updated/merged/removed/unresolved line has been explicitly suppressed.  Only
hg.clean() has the capability to suppress these messages.  Arguably the
updated..resolved line should be present in the two test cases changed here,
but at least the output is consistent for now.

Note that this also affects (the apparently largefiles untested) bisect and
backput commands, as well as hgsubrepo.remove().

diff --git a/hgext/largefiles/overrides.py b/hgext/largefiles/overrides.py
--- a/hgext/largefiles/overrides.py
+++ b/hgext/largefiles/overrides.py
@@ -659,7 +659,8 @@
         newstandins = lfutil.getstandinsstate(repo)
         filelist = lfutil.getlfilestoupdate(oldstandins, newstandins)
 
-    lfcommands.updatelfiles(repo.ui, repo, filelist=filelist, printmessage=True)
+    lfcommands.updatelfiles(repo.ui, repo, filelist=filelist,
+                            printmessage=showstats)
 
     return result
 
diff --git a/tests/test-largefiles.t b/tests/test-largefiles.t
--- a/tests/test-largefiles.t
+++ b/tests/test-largefiles.t
@@ -1708,8 +1708,6 @@
   $ hg clone . ../update_on_clone
   updating to branch default
   cloning subrepo subrepo from $TESTTMP/statusmatch/subrepo
-  getting changed largefiles
-  1 largefiles updated, 0 removed
   5 files updated, 0 files merged, 0 files removed, 0 files unresolved
   getting changed largefiles
   1 largefiles updated, 0 removed
@@ -1723,8 +1721,6 @@
   $ hg -R ../update_on_clone status -S
   M subrepo/large.txt
   $ hg -R ../update_on_clone update -C
-  getting changed largefiles
-  1 largefiles updated, 0 removed
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   getting changed largefiles
   0 largefiles updated, 0 removed


More information about the Mercurial-devel mailing list