NAME

LWP::UserAgent::Patch::FilterMirrorMaxSize - Dont' mirror() files larger than a certain size

VERSION

This document describes version 0.05 of LWP::UserAgent::Patch::FilterMirrorMaxSize (from Perl distribution LWP-UserAgent-Patch-FilterMirror), released on 2015-07-27.

SYNOPSIS

 use LWP::UserAgent::Patch::FilterMirrorMaxSize -size => 10*1024*1024;
 # use LWP::UserAgent's mirror() as usual

To use with CPAN::Mini command-line script:

 % PERL5OPT="-MLWP::UserAgent::Patch::FilterMirrorMaxSize=-size,10485760,-verbose,1" minicpan -l /cpan -r http://mirrors.kernel.org/cpan/

DESCRIPTION

If size is larger than the limit, the patch's wrapper method will return a dummy 304 (not modified) response object. This trick should work on at least some applications (like with CPAN::Mini, which I originally wrote this patch module for), but it might not :-)

SEE ALSO

http://blogs.perl.org/users/steven_haryanto/2014/06/skipping-large-files-when-mirroring-your-mini-cpan.html

HOMEPAGE

Please visit the project's homepage at https://metacpan.org/release/LWP-UserAgent-Patch-FilterMirror.

SOURCE

Source repository is at https://github.com/sharyanto/perl-LWP-UserAgent-Patch-FilterMirror.

BUGS

Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=LWP-UserAgent-Patch-FilterMirror

When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.

AUTHOR

perlancar <perlancar@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2015 by perlancar@cpan.org.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.