diff hgext/largefiles/overrides.py @ 15944:f19d5c852f9b stable

largefiles: add --normal option to hg add (issue3061)
author Na'Tosha Bard <natosha@unity3d.com>
date Fri, 02 Dec 2011 18:20:32 +0100
parents 2dc599583ebe
children 295f8aeab363
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py	Fri Jan 20 11:56:12 2012 +0100
+++ b/hgext/largefiles/overrides.py	Fri Dec 02 18:20:32 2011 +0100
@@ -179,6 +179,11 @@
 # matcher which matches only the normal files and runs the original
 # version of add.
 def override_add(orig, ui, repo, *pats, **opts):
+    normal = opts.pop('normal')
+    if normal:
+        if opts.get('large'):
+            raise util.Abort(_('--normal cannot be used with --large'))
+        return orig(ui, repo, *pats, **opts)
     bad = add_largefiles(ui, repo, *pats, **opts)
     installnormalfilesmatchfn(repo[None].manifest())
     result = orig(ui, repo, *pats, **opts)