Beyond that, there is a long list of Perl modules required, starting with:
-* Date::Parse deb: libtimedate-perl
- pkg: p5-TimeDate
- rpm: perl-TimeDate
-
* Digest::SHA typically installed with Perl
rpm: perl-Digest-SHA
(speeds up process spawning on Linux,
see public-inbox-daemon(8))
+- Date::Parse deb: libtimedate-perl
+ pkg: p5-TimeDate
+ rpm: perl-TimeDate
+ (for broken, mostly historical emails)
+
- Plack::Middleware::ReverseProxy deb: libplack-middleware-reverseproxy-perl
pkg: p5-Plack-Middleware-ReverseProxy
rpm: perl-Plack-Middleware-ReverseProxy
# note: we use spamc(1), NOT the Perl modules
# We also depend on git.
# Keep this sorted and synced to the INSTALL document
- 'Date::Parse' => 0,
# libperl$PERL_VERSION,
# `perl5' on FreeBSD
* imperfect scraper importers for obfuscated list archives
(e.g. obfuscated Mailman stuff, Google Groups, etc...)
-* consider using HTTP::Date instead of Date::Parse, since we need the
- former is capable of parsing RFC822-ish dates, used by Plack, and
- the latter is missing from OpenBSD and maybe other distros.
-
* improve performance and avoid head-of-line blocking on slow storage
* share "git cat-file --batch" processes across inboxes to avoid
essential => [ qw(
git
perl
- Date::Parse
Devel::Peek
Digest::SHA
Email::Simple
# everything optional for normal use
optional => [ qw(
+ Date::Parse
BSD::Resource
DBD::SQLite
DBI
}
# TODO: make Devel::Peek optional, only used for daemon
-my @base_mod = qw(Email::MIME Date::Parse Devel::Peek);
+my @base_mod = qw(Email::MIME Devel::Peek);
my @over_mod = qw(DBD::SQLite DBI);
my %mod_groups = (
-index => [ @base_mod, @over_mod ],
use strict;
use warnings;
use Email::Simple;
-use Date::Parse qw(strptime);
+use PublicInbox::MsgTime;
use constant MAX_SIZE => 1024 * 500; # same as spamc default, should be tunable
use constant MAX_MID_SIZE => 244; # max term size - 1 in Xapian
}
sub usable_date {
- my @t = eval { strptime(@_) };
- scalar @t;
+ defined(eval { PublicInbox::MsgTime::str2date_zone($_[0]) });
}
sub alias_specified {