changeset 23768:6b1428e55728

largefiles: return the list of added files from addlargefiles() This will be used to exclude largefile candidates from the normal file matcher, which will allow add and addremove dryruns to not print a file as both a normal and a large file.
author Matt Harbison <matt_harbison@yahoo.com>
date Wed, 31 Dec 2014 18:31:18 -0500
parents 749dc66e9329
children bb3ee61cfaa1
files hgext/largefiles/overrides.py
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py	Fri Nov 28 21:44:41 2014 -0500
+++ b/hgext/largefiles/overrides.py	Wed Dec 31 18:31:18 2014 -0500
@@ -154,9 +154,11 @@
             bad += [lfutil.splitstandin(f)
                     for f in repo[None].add(standins)
                     if f in m.files()]
+
+        added = [f for f in lfnames if f not in bad]
     finally:
         wlock.release()
-    return bad
+    return added, bad
 
 def removelargefiles(ui, repo, isaddremove, matcher, **opts):
     after = opts.get('after')
@@ -247,7 +249,7 @@
             raise util.Abort(_('--normal cannot be used with --large'))
         return orig(ui, repo, *pats, **opts)
     matcher = scmutil.match(repo[None], pats, opts)
-    bad = addlargefiles(ui, repo, False, matcher, **opts)
+    added, bad = addlargefiles(ui, repo, False, matcher, **opts)
     installnormalfilesmatchfn(repo[None].manifest())
     result = orig(ui, repo, *pats, **opts)
     restorematchfn()