Add isWriting property and writes: parameter
Write lock test

Fixed error reporting for some functions.
Some others converted to libgit2 because git sometimes returns 1 on success.
Disable writing commands when repo is writing
Merge branch 'refs/heads/lock'

Conflicts:
	Xit/XTRepository+Parsing.m