source: trunk/essentials/dev-lang/perl/lib/Net/demos/ftp

Last change on this file was 3181, checked in by bird, 19 years ago

perl 5.8.8

File size: 371 bytes
Line 
1#!/usr/local/bin/perl
2
3use blib;
4use Net::FTP;
5use Getopt::Long;
6
7$opt_debug = undef;
8$opt_firewall = undef;
9
10GetOptions(qw(debug firewall=s));
11
12@firewall = defined $opt_firewall ? (Firewall => $opt_firewall) : ();
13
14foreach $host (@ARGV)
15 {
16 $ftp = Net::FTP->new($host, @firewall, Debug => $opt_debug ? 1 : 0);
17 $ftp->login();
18 print $ftp->pwd,"\n";
19 $ftp->quit;
20 }
21
Note: See TracBrowser for help on using the repository browser.