aboutsummaryrefslogtreecommitdiff
path: root/Annex/FileMatcher.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-01-21 18:46:39 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-01-21 18:49:25 -0400
commit7c3f0eae77b07ccc65c4e30d9eb1288781bd0c02 (patch)
treeaf6b86482c4f67f710349677a48917ac29fa404f /Annex/FileMatcher.hs
parentd71baf07108c4903c444175ca482af1ed4cca1b4 (diff)
benchmarked numcopies .gitattributes in preferred content
Checking .gitattributes adds a full minute to a git annex find looking for files that don't have enough copies. 2:25 increasts to 3:27. I feel this is too much of a slowdown to justify making it the default. So, exposed two versions of the preferred content expression, a slow one and a fast but approximate one. I'm using the approximate one in the default preferred content expressions to avoid slowing down the assistant.
Diffstat (limited to 'Annex/FileMatcher.hs')
-rw-r--r--Annex/FileMatcher.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Annex/FileMatcher.hs b/Annex/FileMatcher.hs
index 6ec0bace9..b26a0d7ac 100644
--- a/Annex/FileMatcher.hs
+++ b/Annex/FileMatcher.hs
@@ -70,7 +70,8 @@ parseToken checkpresent checkpreferreddir groupmap t
[ ("include", limitInclude)
, ("exclude", limitExclude)
, ("copies", limitCopies)
- , ("numcopiesneeded", limitNumCopiesNeeded)
+ , ("lackingcopies", limitLackingCopies False)
+ , ("approxlackingcopies", limitLackingCopies True)
, ("inbackend", limitInBackend)
, ("largerthan", limitSize (>))
, ("smallerthan", limitSize (<))