Author: sparky Date: Sat Jun 26 17:04:45 2010 New Revision: 11589 Added: toys/rsget.pl/Direct/FTP (contents, props changed) Log: - plugin for downloading files from ftp://, somewhat problematic as rsget.pl newer was developed with ftp protocol in mind
Added: toys/rsget.pl/Direct/FTP ============================================================================== --- (empty file) +++ toys/rsget.pl/Direct/FTP Sat Jun 26 17:04:45 2010 @@ -0,0 +1,27 @@ +# $Id$ +# Direct::FTP - File getter plugin for rsget.pl +# +# 2010 (c) Przemysław Iskra <[email protected]> +# This program is free software, +# you may distribute it under GPL v2 or newer. + +name: FTP +short: Direct::FTP +web: "http://rsget.pl/getters/Direct/FTP/" +uri: qr{ftp://.*[^/]} +slots: max +status: OK 2010-06-26 + +start: + GET( $-{_uri}, headonly => 1 ); + + my ( $len ) = /^Content-Length:\s*(\d+)\r?$/mi; + $len ||= -1; + + my ( $name ) = $-{_uri} =~ m{.*/(.*)$}; + + INFO( name => $name, size => $len ); + + DOWNLOAD( $-{_uri} ); + +# vim: filetype=perl:ts=4:sw=4 _______________________________________________ pld-cvs-commit mailing list [email protected] http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit
