What steps will reproduce the problem?

1. Create a fresh git-annex repository
2. Add a directory tree to it with about 300,000 files in it
3. wait
4. change the tree; attempt a git commit

What is the expected output? What do you see instead?

git commit hangs due to the large number of loose objects created during the git annex add. If git annex had stopped to repack the git repo a few times along the way, I think this might have been avoided.

What version of git-annex are you using? On what operating system?

git-annex version: 4.20130323
local repository version: 3
default repository version: 3
supported repository versions: 3 4
upgrade supported from repository versions: 0 1 2
build flags: Assistant Webapp Pairing Testsuite S3 WebDAV FsEvents XMPP DNS

Darwin pluto.local 12.3.0 Darwin Kernel Version 12.3.0: Sun Jan  6 22:37:10 PST 2013; root:xnu-2050.22.13~1/RELEASE_X86_64 x86_64
(Mac OS 10.8.3)

git version 1.8.2

> Based on the benchmarks below, repacking even once does not speed things
> up; repacking repeatedly as `git annex add` runs would slow things down.
> 
> It might be worth following up with the git developers why `git commit`
> scans loose objects after it has already output the commit sha1sum.
> 
> Don't see any improvements git-annex can make. [[done]] --[[Joey]]
