On Nov 21, 2009, at 10:18 AM, Mark Lodato wrote:

> On Sat, Nov 21, 2009 at 2:18 AM, Robert Bradshaw
> <[email protected]> wrote:
>> True, though the target audience is much more likely to have a good
>> internet connection, and when downloading it's compressed to about
>> half that. (I pity the developer trying to use Cython on a machine
>> where half a dozen MB is a consequential burden on their hard drive.)
>
> Just to make this explicit, the .hg directory only adds about 3.4 MB
> to the download, not 6.4MB (or 7.6MB).  Here are some test results:
>
> 464K    cython-devel.tar.bz2
> 564K    cython-devel.tar.gz
> 3.1M    cython-devel_withgit.tar.bz2
> 3.2M    cython-devel_withgit.tar.gz
> 3.8M    cython-devel_withhg.tar.bz2
> 3.9M    cython-devel_withhg.tar.gz
> 3.0M    cython-devel/.git
> 7.6M    cython-devel/.hg
>
> Explanation:
> * cython-devel is working tree only
> * cython-devel_withhg is working tree + .hg directory (same as we  
> currently do)
> * cython-devel_withgit is working tree + .git directory (after running
> hg-fast-export and doing git gc --aggressive)
> * cython-devel/.hg is size of extracted .hg directory
> * cython-devel/.git is size of extracted .git directory

Interesting stats.

>> Anyway, that's my long-winded defense of those 6.4 MB. A script to
>> turn a simple source directory into a full-blown repository would
>> nearly meet the above goals, and is probably not that hard. Anyone
>> want to submit a patch? :-)
>
> Here's a proof of concept.  I haven't tested it, and I don't know Hg
> well, so this may not be good.  It might be better to turn this into a
> Makefile target rather than a script.
>
> #!/bin/bash -x -e
> tag=0.11.3
> repo=http://hg.cython.org/cython-devel
> tmpdir=`mktemp --tmpdir=. -d`
> hg clone $repo $tmpdir
> cd $tmpdir
> hg update $tag
> cd ..
> mv $tmpdir/{.hg,.hgtags} .
> rm -rf $tmpdir

Thanks. I was hoping it wouldn't be anything messy, but that seems to  
do it (except that --tmpdir isn't a standard posix option). I agree,  
I'll turn this into a Makefile. Probably too big of a change to put  
into 0.12 at this point, but I'll turn this into a makefile.

- Robert


_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to