1 |
On 08/08/2012 11:35 AM, W-Mark Kubacki wrote: |
2 |
> Hi Portage devs, |
3 |
> |
4 |
> Can I send patches by `git send-email` or do you prefer attachments? |
5 |
|
6 |
Either way is fine. |
7 |
|
8 |
> The patch applies to master/HEAD and can be backported to 2.1*. Its |
9 |
> description is as follows: |
10 |
> |
11 |
> Portage writes a compressed copy of 'Packages' index file. |
12 |
> |
13 |
> This behaviour is enabled by FEATURES="compress-index". The |
14 |
> resulting file is 'Packages.gz' and its modification time will |
15 |
> match that of 'Packages'. |
16 |
> |
17 |
> Web-servers use that copy to avoid repeated on-the-fly compression. |
18 |
> |
19 |
> In order to re-use 'atomic_ofstream' usage of 'codecs.zlib_codec' |
20 |
> has been considered and discarded, because 'GzipFile' yields |
21 |
> smaller files. (According to Mark's tests 62% smaller.) |
22 |
> |
23 |
> Example usage, Nginx: |
24 |
> |
25 |
> location =/Packages { |
26 |
> gzip_static on; |
27 |
> default_type text/plain; |
28 |
> } |
29 |
> |
30 |
> Apache httpd (use with caution): |
31 |
> |
32 |
> RewriteRule ^(.*)/Packages$ $1/Packages.gz |
33 |
> [T=text/plain,E=GZIP:gzip,L] |
34 |
> <FilesMatch "Packages\.gz$"> |
35 |
> Header set Content-Encoding gzip |
36 |
> </FilesMatch> |
37 |
> |
38 |
|
39 |
Thanks, I've applied your patch: |
40 |
|
41 |
http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=11c0619c63b54346ee5c67cd67ab1ccb24f5f947 |
42 |
|
43 |
-- |
44 |
Thanks, |
45 |
Zac |