1 |
#!/usr/bin/perl |
2 |
|
3 |
use strict; |
4 |
use warnings; |
5 |
|
6 |
|
7 |
use MIME::Lite; |
8 |
|
9 |
use lib qw( /data/libs/nfo/perl/libs ); |
10 |
use org::netfrag::shortcuts qw( now ); |
11 |
|
12 |
my $now = now(); |
13 |
|
14 |
#my $to = 'joko@netfrag.org'; |
15 |
my $to = 'links-computing@netfrag.org'; |
16 |
my $subject = |
17 |
"This is just a test mail. Please ignore it." . "\n" . |
18 |
"-- generated $now" . "\n"; |
19 |
my $data = "$subject"; |
20 |
|
21 |
my $msg = MIME::Lite->new( |
22 |
# From => 'test@localhost', |
23 |
# From => 'test', |
24 |
From => 'test@netfrag.org', |
25 |
To => "$to", |
26 |
Subject => "$subject", |
27 |
Data => "$data\n", |
28 |
); |
29 |
my $str = $msg->as_string; |
30 |
|
31 |
print $str; |
32 |
|
33 |
1; |
34 |
|