Skip Menu |

This queue is for tickets about the Email-Stuff CPAN distribution.

Report information
The Basics
Id: 66052
Status: resolved
Priority: 0/
Queue: Email-Stuff

People
Owner: Nobody in particular
Requestors: ZARQUON [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 0.02
  • 0.03
  • 0.04
  • 0.05
  • 0.06
  • 0.07
  • 0.08
  • 2.00
  • 2.02
  • 2.03
  • 2.04
  • 2.05
  • 2.06
  • 2.07
  • 2.08
  • 2.09
  • 2.100
  • 2.101
  • 2.102
Fixed in: (no value)



Subject: Doc patch
Patch for doc improvements - especially explicitly showing how to override default mailer.
Subject: email-stuff.diff
diff --git a/Changes b/Changes index 0ff2d59..797db32 100644 --- a/Changes +++ b/Changes @@ -1,4 +1,6 @@ Revision history for Perl extension Email::Stuff +2.103 2011-02-23 + Documentation improvements (kd). 2.102 2010-02-14 minor documentation improvements diff --git a/lib/Email/Stuff.pm b/lib/Email/Stuff.pm index 8d2c10e..0eb2ba0 100644 --- a/lib/Email/Stuff.pm +++ b/lib/Email/Stuff.pm @@ -11,22 +11,19 @@ Email::Stuff - A more casual approach to creating and sending Email:: emails Dear Santa I have killed Bun Bun. - - Yes, I know what you are thinking... but it was actually a total accident. - - I was in a crowded line at a BayWatch signing, and I tripped, and stood on his head. - + Yes, I know what you are thinking... but it was actually a total accident. I + was in a crowded line at a BayWatch signing, and I tripped, and stood on his + head. I know. Oops! :/ - - So anyways, I am willing to sell you the body for $1 million dollars. - - Be near the pinhole to the Dimension of Pain at midnight. - + + So anyways, I am willing to sell you the body for $1 million dollars. Be + near the pinhole to the Dimension of Pain at midnight. + Alias - + AMBUSH_READY - - # Create and send the email in one shot + + # Create and send the email in one shot, and send via sendmail Email::Stuff->from ('cpan@ali.as' ) ->to ('santa@northpole.org' ) ->bcc ('bunbun@sluggy.com' ) @@ -35,6 +32,15 @@ Email::Stuff - A more casual approach to creating and sending Email:: emails filename => 'dead_bunbun_proof.gif') ->send; + # Construct email before sending and send with SMTP. + + my $mail = Email::Stuff->from('cpan@ali.as'); + $mail->to('santa@northpole.org') + # and so on ... + my $mailer = Email::Send->new({mailer => 'SMTP'}); + $mailer->mailer_args([Host => 'smtp.example.com:465', ssl => 1]); + $mail->send($mailer); + =head1 DESCRIPTION B<The basics should all work, but this module is still subject to @@ -57,9 +63,10 @@ to do things properly. =head2 Default Mailer -Although it cannot be relied upon to work, the default behaviour is to use -sendmail to send mail, if you don't provide the mail send channel with -either the C<using> method, or as an argument to C<send>. +Email::Stuff uses L<Email::Send> to send messages. Although it cannot be +relied upon to work, the default behaviour is to use sendmail to send mail, if +you don't provide the mail send channel with either the C<using> method, or as +an argument to C<send>. The use of sendmail as the default mailer is consistent with the behaviour of the L<Email::Send> module itself. @@ -171,7 +178,7 @@ use prefork 'File::Type'; use vars qw{$VERSION}; BEGIN { - $VERSION = '2.102'; + $VERSION = '2.103'; } ##################################################################### @@ -565,7 +572,8 @@ sub as_string { =head2 send -Sends the email via L<Email::Send>. +Sends the email via L<Email::Send>. Optionally pass in a Mail:Send object to +override the default mailer. =cut @@ -648,6 +656,12 @@ All bugs should be filed via the CPAN bug tracker at L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Email-Stuff> +=head1 SOURCE + +The current version is available via CPAN: +L<http://search.cpan.org/dist/Email-Stuff/>. The version control repository is +hosted at github: L<https://github.com/rjbs/email-stuff>. + =head1 AUTHORS B<Current maintainer>: Ricardo Signes C<rjbs@cpan.org>
Applied in git. -- rjbs