From mboxrd@z Thu Jan 1 00:00:00 1970 From: cgit at cryptocrack.de (Lukas Fleischer) Date: Sun, 16 Jun 2013 09:56:55 +0200 Subject: RFE: download patch between arbitrary revisions In-Reply-To: <20130613222126.GC23890@serenity.lan> References: <51ABEF0F.3030909@kernel.org> <20130603184953.GK1072@serenity.lan> <20130613215810.GB29281@blizzard> <20130613222126.GC23890@serenity.lan> Message-ID: <20130616075655.GA27832@blizzard> On Thu, Jun 13, 2013 at 11:21:26PM +0100, John Keeping wrote: > On Thu, Jun 13, 2013 at 11:58:10PM +0200, Lukas Fleischer wrote: > > On Mon, Jun 03, 2013 at 07:49:53PM +0100, John Keeping wrote: > > > On Sun, Jun 02, 2013 at 09:19:11PM -0400, Konstantin Ryabitsev wrote: > > > > There is currently a way to render a diff between two arbitrary objects, > > > > e.g.: > > > > > > > > https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/diff/?id=v3.10-rc4&id2=v3.10-rc3 > > > > > > > > However, there doesn't appear to be a way to download a patch in the > > > > same way -- it will only make patch against id's parent. E.g.: > > > > > > > > https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/patch/?id=v3.10-rc4&id2=v3.10-rc3 > > > > > > > > Any way we can make the behaviour of patch match that of diff? > > > > [...] > > So: > > /patch/?id=v1.8.3.1&id2=v1.8.3 > > generates something like "git format-patch v1.8.3..v1.8.3.1". And > > /rawdiff/?id=v1.8.3.1&id2=v1.8.3 > > generates the diff with no HTML around it. > > The latter could be a query parameter instead ("raw=1"?). Having not > investigated the impact on the code, I have no preference for one over > the other. Sounds good to me either way. Jason? Also, I just wondered whether this could be used to DoS servers when requesting a series of patches for a huge range of revisions... Maybe there should be some kind of limit?