Create a new direct reference from an OID.
the reference name
the object id for a direct reference
the first non-tag object's OID, or NULL
the created git_reference or NULL on error