Re: Why does diff --binary include content of files being deleted?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Allan Wind <allan_wind@xxxxxxxxxxxxxxxxx> wrote:
> On 2008-06-21T23:51:18-0400, Shawn O. Pearce wrote:
> > In order to apply the diff in reverse we need the old binary data
> > in the diff output.  So that's why its larger.
> 
> Makes sense, thanks.  In my use case (where I do not need the reverse 
> diff) this adds 500+ MB or 43159% overhead.

Well, then in that case you have to omit --binary I think, or use a
filter script to strip out the binary data from the resulting patch.

> When I tried to apply the large diff my virtual private server with 512 
> MB of memory git apply ran out of memory and died.  Is there any way to 
> bound the memory usage of git apply?

If you submit patches for it.  ;-)

git-apply today is meant for applying small patches, like those that
would typically be written by a developer hacking on open source
software.  It tries to be completely atomic; either the entire
patch applies at once, or the entire patch rejects with no changes
being made to the local directory.  As such it applies everything in
memory, and only writes out when we are sure the patch applies clean.

So no, there isn't a way to make git-apply use less memory.

-- 
Shawn.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux