Remove target directory and add it to .gitignore

This is the maven output folder and should not be included in the
history.
Speed up implementation of checking out a commit

Before, this was implemented by using a clone, then reset and at the end
deleting the .git directory. This is inefficient for multiple reasons.

It can be implemented much more efficiently by walking the tree behind
the commit and creating the directories and files.

Benchmarked with the jgit repository:

Before: Used at least 48 GB and 3.5 hours, I aborted it during "Cleaning
up mined directories".

After: Used at most 28 GB and took 4 minutes (!).

It could be made more efficient by using hardlinks/symlinks to refer to
files whose contents have not changed from one commit to the next. This
would be pretty simple to implement by remembering where a certain blob
object ID was checked out (in a Map) and if encountering it again, link
there instead of creating another file with the same contents. The only
thing that would be a bit tricky is to get it right for parallelism.

Another option would be to offer access to the commit data via a FUSE
file system implementation, which would read the data from the
repository on access. The downside of this would be a dependency to
FUSE, making it less portable.
Merge pull request #8 from robinst/efficient-checkout

 Speed up implementation of checking out a commit by robinst