Refactors credentials callback on remote to make pushes authenticate

https://github.com/libgit2/pygit2/issues/437

There's a single test break in this:
```
======================================================================
FAIL: test_remote_refcount (test.test_remote.RepositoryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/dalbrecht/pygit2/test/test_remote.py", line 189, in test_remote_refcount
    self.assertEqual(start, end)
AssertionError: 2 != 3

----------------------------------------------------------------------
Ran 228 tests in 9.560s

FAILED (failures=1)
```

It looks like the patch is causing the refcount to get thrown. If someone could take a look at why this is happening, we can get this merged and pushes should work with credentials.