Created
January 26, 2011 21:36
-
-
Save lfittl/797522 to your computer and use it in GitHub Desktop.
Fix for fossil's git export function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/src/export.c b/src/export.c | |
| index d776854..2a91805 100644 | |
| --- a/src/export.c | |
| +++ b/src/export.c | |
| @@ -41,7 +41,7 @@ static void print_person(const char *zUser){ | |
| db_reset(&q); | |
| for(i=0; zUser[i] && zUser[i]!='>' && zUser[i]!='<'; i++){} | |
| if( zUser[i]==0 ){ | |
| - printf(" <%s>", zUser); | |
| + printf(" %s <%s>", zUser, zUser); | |
| return; | |
| } | |
| zName = mprintf("%s", zUser); | |
| @@ -101,7 +101,7 @@ static void print_person(const char *zUser){ | |
| void export_cmd(void){ | |
| Stmt q; | |
| int i; | |
| - int firstCkin; /* Integer offset to check-in marks */ | |
| + int firstCkin; /* Offset to seperate blob marks from check-in marks */ | |
| Bag blobs, vers; | |
| bag_init(&blobs); | |
| bag_init(&vers); | |
| @@ -130,7 +130,7 @@ void export_cmd(void){ | |
| /* Output the commit records. | |
| */ | |
| - firstCkin = db_int(0, "SELECT max(rid) FROM blob")+1; | |
| + firstCkin = db_int(0, "SELECT max(fid) FROM mlink")+1; | |
| db_prepare(&q, | |
| "SELECT strftime('%%s',mtime), objid, coalesce(comment,ecomment)," | |
| " coalesce(user,euser)," |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
FYI - The first hunk is unrelated to the blob/commit mark number issue.