my $gm = Geo::Mirror->new(mirror_file => '/path/to/mirrors.txt');
my $mirror = $gm->closest_mirror_by_country('us', $freshness); # $freshness optional, see description below my $mirror = $gm->closest_mirror_by_addr('184.108.40.206', $freshness); # $freshness optional, see description below
The mirror file should be a space separate list of URL, Country, and mirror freshness. The mirror freshness is optional and can be used by user request a mirror with a minimum freshness.
All rights reserved. This package is free software; you can redistribute it and/or modify it under the same terms as Perl itself.