fix transport support in the dispatcher so it can be overridden at runtime
[p5sagit/Promulger.git] / script / make_message
1 #!/usr/bin/perl
2 use strict;
3 use warnings;
4
5 use Email::MIME;
6 use File::Slurp 'read_file';
7
8 my ($from, $to, $subject) = @ARGV;
9 my $body = read_file \*STDIN;
10
11
12 my $email = Email::MIME->create(
13   header => [
14     From => $from,
15     To   => $to,
16     Subject => $subject,
17   ],
18   body => $body,
19 );
20 print $email->as_string;