example_cpan_caching_proxy.pl untested

filter: Statementstmt 0.0% 0 / 17 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 4 Podpod n/a totaltotal 0.0% 0 / 21 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 #!/usr/bin/perl
2  
3 use strict;
4 use CPAN::CachingProxy;
5 use CGI;
6 use CGI::Carp qw(fatalsToBrowser);
7  
8 die "please use 'wget -qO - http://www.cpan.org/MIRRORED.BY | grep dst_http | less' to select a proxy";
9  
10 my $mirror = "http://www.perl.com/FAKE";
11 my $keyspace = "CK0"; # just increment this to "reset" the cache
12  
13 CPAN::CachingProxy->new(
14  
15 mirrors => [$mirror],
16 key_space => $keyspace,
17 cache_root => "/home/voltar/nobody.cache/",
18 debug => 0,
19  
20 )->run;
21