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

Re: [devel-ref] author/homepage in description



I did some quick math to see how much a Packages file will grow
if we add a Homepage URL. 
	
The number of unique URLs currently being used:

[tornado;~]-32> grep http: /var/lib/dpkg/available | sed -e 's/.*\(http:[^[:space:]]*\).*/\1/' | sort | uniq | wc -l
    744

The amount of data currently used by URLs:

[tornado;~]-33> grep http: /var/lib/dpkg/available | sed -e 's/.*\(http:[^[:space:]]*\).*/\1/' | sort | uniq | wc -c           
  25919

The total number of available packages:

[tornado;~]-34> grep -c '^Package:' /var/lib/dpkg/available
11516

>From this data we can calculate the average size of a URL:
25919 / 744 = 34.837 characters.

If we use the name "Homepage" as field name that means we will end up
using 11516 * (10 + 34.837) = 516342.892 or approximately 504 kilobyte
of data.

As a result of this the Packages file will increase 516343 - 25919 = 490424 
bytes, or around 479 kilobyte. That is a lot of data for people using
modems.

Wichert.

-- 
Wichert Akkerman <wichert@wiggy.net>           http://www.wiggy.net/
A random hacker



Reply to: