Fix build break by upgrading git2-rs

Update git2-rs to the latest version which includes a fix for `extern crate`
syntax changes.  This version changes the interface for credential callbacks,
so update the git source provider code as well.
Fix obsolete `extern crate` syntax in some of the tests
auto merge of #554 : bkoropoff/cargo/update-git2, r=alexcrichton

This is pretty simple.  Do the existing unit tests sufficiently cover the git2-related changes?