Skip to content

Commit 74ffce2

Browse files
committed
oid: introduce git_oid_t
We require an enumeration to help us identify the different types of object IDs. Currently, we only support SHA1 but we will support SHA256 in the future.
1 parent 0acaf3a commit 74ffce2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

include/git2/oid.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,11 @@
1919
*/
2020
GIT_BEGIN_DECL
2121

22+
/** The type of object id, currently only SHA1. */
23+
typedef enum {
24+
GIT_OID_SHA1 = 1 /**< SHA1 */
25+
} git_oid_t;
26+
2227
/** Size (in bytes) of a raw/binary oid */
2328
#define GIT_OID_SHA1_SIZE 20
2429

0 commit comments

Comments
 (0)