Do you know where your variables are? | |
PerlMonks |
dumpcpanurls: current configured CPAN mirror URLsby Intrepid (Deacon) |
on Aug 08, 2003 at 22:09 UTC ( [id://282325]=CUFP: print w/replies, xml ) | Need Help?? |
Provides a perl admin or user with the list (assuming CPAN.pm has been configured previously)
of the mirror site URLs that will be queried when CPAN is next run.
Updated on November 7 2004Updated on Mon, 25 Apr 2005 UTC: added url for netselect
Same thing as a one-liner (*nix or MSwindoze):
As a further (obvious) tip, note that this list can then be used as input into a pipeline, say to the ping(1) command, i.e.: or to the netselect command if you have it: or doing this all in perl without the extra shell pipelines: or a little more conservatively:
It's Perl. TMTOWTDI :-) Finding out that the first host in the list is down before running CPAN can be a Good Thing. Finding out which mirror seems fastest is also nice. ;-)
Back to
Cool Uses for Perl
|
|