=item -y Send it using Mail::WebMail::Yahoo (if you can) You will be prompted for a password.
--- cpanpluscpantest 2002-11-12 03:04:10.000000000 -0800 +++ cpanpluscpantest.yahoo 2002-11-12 03:18:59.000000000 -0800 @@ -14,7 +14,7 @@ =head1 USAGE cpantest -g grade [ -nc ] [ -auto ] [ -p package ] - [ -t text | -f file ] [ email-addresses ] + [ -t text | -f file ] [-y] [ email-addresses ] For MacPerl, save as a droplet, and drop a module archive or unpacked folder on the droplet. @@ -59,6 +59,11 @@ Autosubmission (non-interactive); you won't be prompted to supply any information that you didn't provide on the command line. Implies I<- +nc>. +=item -y + +Send it using Mail::WebMail::Yahoo (if you can) +You will be prompted for a password. + =item email-addresses A list of additional email addresses that should be cc:'d in this @@ -109,6 +114,7 @@ use vars qw( $Grade $Package $No_comment $Automatic $Comment_text $Comment_file $MacApp $MacMPW + $Yahoo ); $MacMPW = $^O eq 'MacOS' && $MacPerl::Version =~ /MPW/; @@ -124,6 +130,7 @@ 'auto', \$Automatic, 't=s', \$Comment_text, 'f=s', \$Comment_file, + 'y', \$Yahoo, ) or usage(); $CC = join ' ', @ARGV; @@ -232,10 +239,21 @@ print "To: $CPAN_testers\n"; print "Cc: $CC\n" if defined $CC; - if (prompt('S)end/I)gnore', 'Ignore') !~ /^[Ss]/) { - print "Ignoring message.\n"; - exit 1; + my $WhatToDo = prompt('Send/Yahoo/Ignore', 'Ignore'); + + if ( $WhatToDo !~ /^[Ss]/ ) { + if( $WhatToDo =~ /^[Yy]/ ) { + SendItUsingYahooo(); + }else { + print "Ignoring message.\n"; + exit 1; + } } + +} + +if( $Yahoo ) { + SendItUsingYahooo(); } $msg = new Mail::Send Subject => $subject, To => $CPAN_testers; @@ -299,6 +317,25 @@ } +sub SendItUsingYahooo { + my $u = prompt('yahoo id)', $ENV{USER} || $ENV{USERNAME} || "" ); + my $p = prompt('password', ''); + + die "BOTH username AND password ARE REQUIRED!" unless $u and $p; + + require Mail::Webmail::Yahoo; + my $y = Mail::Webmail::Yahoo->new(username => $u, password => $p +) ||die $@; + $y->trace(0); + $y->login() or die $@; + + open(REPORT,$Report) or die "couldn't open $Report $!"; + local $/; + $Report = <REPORT>; + close(REPORT); + $y->send( $CPAN_testers, $subject, $Report ) or die $@; + exit(0); +} + # Prompt for a new value for $label, given $default; return the user' +s # selection. sub prompt @@ -320,19 +357,20 @@ print "Error: $message\n" if defined $message; print "Usage:\n"; print " cpantest -g grade [ -nc ] [ -auto ] [ -p package ]\n"; - print " [ -t text | -f file ] [ email-addresses ]\n"; + print " [ -t text | -f file ] [-y ] [ email-addresses ] +\n"; print " -g grade Indicates the status of the tested package.\n" +; print " Possible values for grade are:\n"; foreach (keys %Grades) { printf " %-10s %s\n", $_, $Grades{$_}; } - + print " -y Specify a short comment.\n"; print " -t Specify a short comment.\n"; print " -f Specify a file comtaining comments.\n"; print " -p Specify the name of the distribution tested.\n +"; print " -nc No comment; you will not be prompted to commen +t on\n"; print " the package.\n"; + print " -y Send it using Mail::WebMail::Yahoo (if you can +)\n"; print " -auto Autosubmission (non-interactive); implies -nc. +\n"; exit 1;
In reply to Mail::Webmail::Yahoo enabled cpantest by PodMaster
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |