These aren't really supported and will probably be replaced with
better tools, but PublicInbox::Eml should be readily available
to anybody who already has our source tree.
=cut
use strict;
use warnings;
=cut
use strict;
use warnings;
use Date::Parse qw/str2time/;
use Date::Parse qw/str2time/;
use PublicInbox::Git;
use PublicInbox::Import;
sub usage { "Usage:\n".join('', grep(/\t/, `head -n 24 $0`)) }
use PublicInbox::Git;
use PublicInbox::Import;
sub usage { "Usage:\n".join('', grep(/\t/, `head -n 24 $0`)) }
foreach my $sub (qw(cur new)) {
foreach my $fn (glob("$dir/$sub/*")) {
open my $fh, '<', $fn or next;
foreach my $sub (qw(cur new)) {
foreach my $fn (glob("$dir/$sub/*")) {
open my $fh, '<', $fn or next;
- my $s = Email::Simple->new(do { local $/; <$fh> });
+ my $s = PublicInbox::Eml->new(do { local $/; <$fh> });
my $date = $s->header('Date');
my $t = eval { str2time($date) };
defined $t or next;
my $date = $s->header('Date');
my $t = eval { str2time($date) };
defined $t or next;
while (my $ary = pop @msgs) {
my $fn = "$dir/$ary->[1]";
open my $fh, '<', $fn or next;
while (my $ary = pop @msgs) {
my $fn = "$dir/$ary->[1]";
open my $fh, '<', $fn or next;
- my $mime = PublicInbox::MIME->new(do { local $/; <$fh> });
+ my $mime = PublicInbox::Eml->new(do { local $/; <$fh> });
$im->add($mime);
}
$im->done;
$im->add($mime);
}
$im->done;
use strict;
use warnings;
use PublicInbox::Config;
use strict;
use warnings;
use PublicInbox::Config;
use PublicInbox::Import;
use PublicInbox::Git;
sub usage { "Usage:\n".join('',grep(/\t/, `head -n 10 $0`)) }
use PublicInbox::Import;
use PublicInbox::Git;
sub usage { "Usage:\n".join('',grep(/\t/, `head -n 10 $0`)) }
$max = $n + $max_gap;
print STDERR $fn, "\n";
$max = $n + $max_gap;
print STDERR $fn, "\n";
- my $mime = PublicInbox::MIME->new(do { local $/; <$fh> });
+ my $mime = PublicInbox::Eml->new(do { local $/; <$fh> });
$filter->scrub($mime);
$im->add($mime);
$filter->scrub($mime);
$im->add($mime);