title: Checkout of git repository in pure PHP
body: <p>I need to to a git checkout in pure PHP.
  I already tried this ( <a href="http://www.phpclasses.org/package/5310-PHP-Retrieve-project-files-from-GIT-repositories.html" rel="nofollow">http://www.phpclasses.org/package/5310-PHP-Retrieve-project-files-from-GIT-repositories.html</a> ) with HTTP and SASL, but I didn't really work.
  Then I took a look at GLIP ( <a href="https://github.com/patrikf/glip" rel="nofollow">https://github.com/patrikf/glip</a> ), but that doesn't seem to have any functionality like this.
  Basically I need to</p>
  
  <p>-replicate/clone a remote git repository</p>
  
  <p>-"extract" master branch files into a specified directory</p>
  
  <p>The main problem with PHP GIT is, that it just didn't supported all possible changes you could do in a commit. Only new files, no moving around of files. And it was also unable to extract files.</p>
  
  <p>/edit:
  git is not installed and I also cannot install git</p>