Format a git_oid into a partial hex string.
output hex string; you say how many bytes to write. If the number of bytes is > GIT_OID_SHA1_HEXSIZE, extra bytes will be zeroed; if not, a '
0' terminator is NOT added.
number of characters to write into out string
0 on success or error code