Martin Langhoff <martin.langhoff@gmail.com> writes:It shouldn't be too tricky to enhance "git am" (git-apply called at around line 49 in it) to grok binary differences for this purpose, because you would have both pre- and post-image blob in your object database, because the patch is being used only to replay what you have in your reository, and it records their abbreviated SHA1 name. I've never felt need to "merge" the binary files myself and had never got around doing this, but if you are interested, it would go something like this: . Make "index %.7s..%.7s" that abbreviates pre- and post- image blob SHA1s in diff.c configurable to spit out full 40 bytes. Call that option --full-index-sha1. . The updated "git rebase" that uses the "format-patch | am" I outlined would pass the --full-index-sha1 to format-patch (which is pased onto underlying diff-tree -p). . In apply.c, check if all of the following holds: * we have both the full 40-byte old_sha1_prefix[] and new_sha1_prefix[]; and * what the index records matches old_sha1_prefix[]; and * the new blob is found in the object database; and for such a path: * change parse_chunk() not to barf even on a binary patch. * change apply_data() to just declare the patch application result is the new blob recorded in the patch. Hmm. - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
| Linus Torvalds | Re: LSM conversion to static interface |
| Ingo Molnar | [patch 03/13] syslets: generic kernel bits |
| Ingo Molnar | Re: [PATCH 6/6] sched: disabled rt-bandwidth by default |
| Greg Kroah-Hartman | [PATCH 001/196] Chinese: Add the known_regression URI to the HOWTO |
git: | |
| David Miller | [GIT]: Networking |
| Gregory Haskins | [RFC PATCH 00/17] virtual-bus |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
