diff --git a/stagit.c b/stagit.c index 12a76a4..1cdaee8 100644 --- a/stagit.c +++ b/stagit.c @@ -977,7 +977,7 @@ writefilestree(FILE *fp, git_tree *tree, const char *path) git_object *obj = NULL; git_off_t filesize; const char *entryname; - char filepath[PATH_MAX], entrypath[PATH_MAX]; + char filepath[PATH_MAX], entrypath[PATH_MAX], oid[8]; size_t count, i, lc; int r, ret; @@ -1031,7 +1031,10 @@ writefilestree(FILE *fp, git_tree *tree, const char *path) fprintf(fp, "m---------", relpath); xmlencode(fp, entrypath, strlen(entrypath)); - fputs("\n", fp); + fputs(" @ ", fp); + git_oid_tostr(oid, sizeof(oid), git_tree_entry_id(entry)); + xmlencode(fp, oid, strlen(oid)); + fputs("\n", fp); } }