diff options
Diffstat (limited to 'include/git2/tree.h')
-rw-r--r-- | include/git2/tree.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/include/git2/tree.h b/include/git2/tree.h index 65d8cc16e..d94b446c2 100644 --- a/include/git2/tree.h +++ b/include/git2/tree.h @@ -199,6 +199,17 @@ GIT_EXTERN(git_otype) git_tree_entry_type(const git_tree_entry *entry); GIT_EXTERN(git_filemode_t) git_tree_entry_filemode(const git_tree_entry *entry); /** + * Get the raw UNIX file attributes of a tree entry + * + * This function does not perform any normalization and is only useful + * if you need to be able to recreate the original tree object. + * + * @param entry a tree entry + * @return filemode as an integer + */ + +GIT_EXTERN(git_filemode_t) git_tree_entry_filemode_raw(const git_tree_entry *entry); +/** * Compare two tree entries * * @param e1 first tree entry @@ -208,7 +219,7 @@ GIT_EXTERN(git_filemode_t) git_tree_entry_filemode(const git_tree_entry *entry); GIT_EXTERN(int) git_tree_entry_cmp(const git_tree_entry *e1, const git_tree_entry *e2); /** - * Convert a tree entry to the git_object it points too. + * Convert a tree entry to the git_object it points to. * * You must call `git_object_free()` on the object when you are done with it. * |