]>
Sergey Matveev's repositories - public-inbox.git/log
Eric Wong [Sat, 6 Sep 2014 23:31:40 +0000 (23:31 +0000)]
view: reduce redundant linkage in index
There's no point in having a "(more...)" and "link" pointing
to the same element, replace "link" with "more..." if we've
omitted text from the index.
Eric Wong [Wed, 3 Sep 2014 20:43:33 +0000 (20:43 +0000)]
view: increase context in index views
It's probably better to show too much than too little, even
if this means extra scrolling :<
Otherwise, we end up punishing messages who quote minimally
and end up loosing context. Unfortunately, too many people
over-quote nowadays.
Eric Wong [Sun, 31 Aug 2014 02:58:07 +0000 (02:58 +0000)]
view: kill leading whitespace in index
Leading whitespace is pointless, but some folks end up adding
it for some reason.
Eric Wong [Sun, 31 Aug 2014 02:52:27 +0000 (02:52 +0000)]
view: show quotes in index if parent is too old
It's helpful to show context if a message does not
appear on the current index page.
Eric Wong [Thu, 28 Aug 2014 05:06:41 +0000 (05:06 +0000)]
view: tighten up regexps used for trimming index
The previous regexp matches were too aggressive w.r.t. scissors.
We destroy trailing whitespace anyways, so do not worry about it
when cutting signatures and patches off.
Eric Wong [Thu, 28 Aug 2014 04:57:30 +0000 (04:57 +0000)]
view: trim git patches delimited by /^---$/
Patches are usually better viewed standalone and are difficult
to judge when nested. So save precious vertical space in our
message index.
Eric Wong [Thu, 28 Aug 2014 02:15:08 +0000 (02:15 +0000)]
feed: deal with removed files
Sometimes we get spam and need to delete messages,
we must prevent errors on missing messages from propagating.
Eric Wong [Thu, 28 Aug 2014 02:14:47 +0000 (02:14 +0000)]
feed: show permalink to home page
This will make it easier to bookmark an index page with threading
context.
Eric Wong [Thu, 28 Aug 2014 01:33:43 +0000 (01:33 +0000)]
view: increase MAX_INLINE_QUOTED threshold to 12
12 lines is half an 80x24 terminal, so it is probably a reasonable
amount to quote. Often 5 lines was not enough for context. This
feature is mainly to reduce scrolling necessary to view pages.
Eric Wong [Thu, 28 Aug 2014 01:25:12 +0000 (01:25 +0000)]
redo main HTML index to show nested messages
This reduces the need for page reloads in common cases and should
improve reading speed so users do not need to open many browser
tabs. This will hopefully increase an encourage readership.
The downside of this are increased server processing overhead and
easier address scraping by spam bots.
Eric Wong [Wed, 27 Aug 2014 19:34:03 +0000 (19:34 +0000)]
view: Email::Address cache purge is optional
We will reuse the html_footer function in a nested index.
Eric Wong [Tue, 26 Aug 2014 05:46:15 +0000 (05:46 +0000)]
show date in top-level threaded index
This is probably useful information for folks browsing via web
interface. It'll probably make more sense if we show the entire
body in the threaded display, though.
Eric Wong [Mon, 4 Aug 2014 20:24:14 +0000 (20:24 +0000)]
t/view: ensure HTML shows QP text
We need to ensure the HTML output is not mangled, either.
Eric Wong [Mon, 4 Aug 2014 20:16:51 +0000 (20:16 +0000)]
filter: preserve QP when collapsing multipart
HTML clients also tend to send quoted-printable crap in
their plain-text parts, preserve that so it's displayed
correctly for all QP-capable handlers.
Eric Wong [Wed, 2 Jul 2014 19:50:28 +0000 (19:50 +0000)]
doc/dc-dlvr-spam-flow: link to ssoma, too
Some readers may not be familiar with ssoma internals such as
ssoma-rm.
Eric Wong [Wed, 2 Jul 2014 19:46:57 +0000 (19:46 +0000)]
doc/dc-dlvr-spam-flow: include links to relevant projects
Some of these projects are not well known, so link to them
to help new users.
Eric Wong [Wed, 2 Jul 2014 19:33:33 +0000 (19:33 +0000)]
doc: remove HTML
Even with txt2pre, the maintenance/discoverability burden is too
high and lynx still uses too much memory. Unfortunately, we'll have
to keep our INSTALL.html for a while longer on the server since it's
linked, but not index.html!
Eric Wong [Sat, 28 Jun 2014 01:06:31 +0000 (01:06 +0000)]
t/html_index.t: fix warnings in test case
Oops.
Eric Wong [Fri, 30 May 2014 06:51:49 +0000 (06:51 +0000)]
README: reflow and expand initial introduction a bit
Marketing is hard!
Eric Wong [Tue, 27 May 2014 08:30:44 +0000 (08:30 +0000)]
sa_config: just put HTML messages in the mod queue
We can be stricter about HTML email, since none of the lists
hosted here accept HTML.
Eric Wong [Fri, 23 May 2014 09:56:02 +0000 (09:56 +0000)]
spamassassin/user_prefs: do not favor paid whitelist services
Paid reputation management services are not encouraged.
Eric Wong [Fri, 23 May 2014 09:54:38 +0000 (09:54 +0000)]
spamassassin/user_prefs: disable non-English
Too much spam arrives without any readable English, and I (the
server administrator) cannot easily tell if a non-English
message is spam or not.
Eric Wong [Thu, 8 May 2014 22:32:13 +0000 (22:32 +0000)]
slrnspool2maildir: fix help and dir creation
Any existing directory should do.
Eric Wong [Wed, 21 May 2014 15:22:49 +0000 (15:22 +0000)]
MDA: cleanse headers in case of delivery
We nuke DKIM headers because we modify headers and sometimes the
body, which may invalidate the message. We'll also nuke whatever
Mailman nukes from messages to avoid phishing and leaking
information.
Eric Wong [Thu, 8 May 2014 02:19:00 +0000 (02:19 +0000)]
mda: drop RFC2369 support for now
That should be use down stream by delivery agents.
Eric Wong [Wed, 7 May 2014 01:43:09 +0000 (01:43 +0000)]
www: attempt to improve formatting of footer
This looks nicer to me (totally subjective and open to bikeshedding
:P)
Eric Wong [Tue, 6 May 2014 19:44:43 +0000 (19:44 +0000)]
consistently whitespace wrap on <pre> sections
Horizontal scrolling is a usability problem for GUI browsers,
so help them avoid it. I love GUI users, really! :)
Eric Wong [Tue, 6 May 2014 19:30:32 +0000 (19:30 +0000)]
INSTALL: update support status
We probably won't bother with FastCGI until there is interest.
Eric Wong [Mon, 5 May 2014 19:59:56 +0000 (19:59 +0000)]
examples/apache2_perl.conf: set PI_CONFIG
This is easier and lower-impact than setting HOME anywhere.
Eric Wong [Mon, 5 May 2014 19:56:20 +0000 (19:56 +0000)]
www: set charset=UTF-8 in full message view
Oops, this was an oversight.
Eric Wong [Mon, 5 May 2014 08:48:13 +0000 (08:48 +0000)]
learn: set_list_headers on training
This is idempotent, and should actually/really prevent training
loops.
Eric Wong [Mon, 5 May 2014 08:39:14 +0000 (08:39 +0000)]
mda: attempt to prevent training loops
Eric Wong [Mon, 5 May 2014 01:07:54 +0000 (01:07 +0000)]
feed: add atom feed link to the bottom
This should improve navigation as browsers may not make it
obvious there is an Atom feed.
Eric Wong [Mon, 5 May 2014 01:01:13 +0000 (01:01 +0000)]
view: add newline before list-wide footer
Otherwise the reply link gets squished.
Eric Wong [Mon, 5 May 2014 00:57:06 +0000 (00:57 +0000)]
www: multi-line cloneurl maps to multiple lines
URLs may be long, so give each its own line.
Eric Wong [Mon, 5 May 2014 00:47:41 +0000 (00:47 +0000)]
www: add footers to HTML index and message views
Some advertising is necessary.
Eric Wong [Sun, 4 May 2014 01:38:16 +0000 (01:38 +0000)]
add various TODO items
Screen space is precious, and we do not need it in the abbreviated
view.
Eric Wong [Fri, 2 May 2014 23:16:37 +0000 (23:16 +0000)]
view: API cleanup, remove "as_" prefix
These views are not OO, so the "as_" prefix makes little sense
and "as_html" conflicts with Hval, which is OO.
Eric Wong [Fri, 2 May 2014 20:28:43 +0000 (20:28 +0000)]
reduce copies by passing string refs to Email::MIME
This should reduce data copies and memory usage, according
to Email::Simple documentation.
Eric Wong [Fri, 2 May 2014 20:07:59 +0000 (20:07 +0000)]
git cat-file wrapper uses syswrite for writes
The requests we make to git cat-file --batch are guaranteed to be
smaller than the 512 bytes required by PIPE_BUF, so there will be no
partial writes. Bypass Perl IO layers and write directly to the
pipe to avoid needing IO::Handle here.
Eric Wong [Thu, 1 May 2014 18:33:18 +0000 (18:33 +0000)]
thread: limit scope of monkey patch
Future versions of Mail::Thread may be released to fix this bug.
However, since it's been about 8 years since the bug was reported..
Eric Wong [Thu, 1 May 2014 02:30:00 +0000 (02:30 +0000)]
workaround Mail::Thread memory leak
Thanks to Ask for the patch in
https://rt.cpan.org/Public/Bug/Display.html?id=22817
Eric Wong [Thu, 1 May 2014 01:56:34 +0000 (01:56 +0000)]
purge Email::Address cache
This prevents memory bloat in case we're serving many requests
with a large, diverse set of email addresses (potentially from
malicious spammers).
Eric Wong [Wed, 30 Apr 2014 22:58:23 +0000 (22:58 +0000)]
split out WWW package and CGI/PSGI-specific parts
This should allow us to more-easily test with Plack.
Eric Wong [Wed, 30 Apr 2014 22:04:44 +0000 (22:04 +0000)]
examples: make web configs consistent and add README
Hopefully this is enough to get some folks started.
Eric Wong [Wed, 30 Apr 2014 21:39:24 +0000 (21:39 +0000)]
cgi: set charset in responses
This ought to prevent browsers from misguessing/misdetecting
things.
Eric Wong [Wed, 30 Apr 2014 20:24:54 +0000 (20:24 +0000)]
add example configs for Apache2 mod_perl and CGI
These are probably still popular configurations in some
settings, so include sample configurations to get folks
started. These are trickier than an average CGI script
to setup because we rely on pretty URLs from PATH_INFO
and not ugly query parameters.
Eric Wong [Wed, 30 Apr 2014 20:13:54 +0000 (20:13 +0000)]
"git cat-file --batch" wrapper really mod_perl-compatible
IPC::Open* does not work well under mod_perl (probably because
it does funky things with stdout/stderr). So use the POSIX
dup2 functions instead, which work reliably on all POSIX-like
platforms.
Eric Wong [Wed, 30 Apr 2014 19:17:21 +0000 (19:17 +0000)]
cgi: avoid warning after exec
Found with mod_perl2 (as it overrides exit).
Eric Wong [Wed, 30 Apr 2014 01:03:30 +0000 (01:03 +0000)]
cgi: remove dependency on IPC::Run in CGI
We may not have PATH available on some servers (e.g. webrick)
and must rely on the hardcoded system PATH. My installation of
IPC::Run does not seem to work without PATH set in the env,
however normal Perl "open" calls work fine.
Eric Wong [Wed, 30 Apr 2014 01:02:53 +0000 (01:02 +0000)]
config: avoid double-slash in expand_path output
It looks ugly in error messages to have redundant slashes.
Eric Wong [Wed, 30 Apr 2014 00:19:48 +0000 (00:19 +0000)]
cgi: disable warnings for CGI::NOSTICKY
We probably know what we're doing, here...
Eric Wong [Wed, 30 Apr 2014 00:16:55 +0000 (00:16 +0000)]
favor "--git-dir=..." over "--git-dir ..."
This might improve grep-ability slightly and reduce allocations
while we're at it.
Eric Wong [Wed, 30 Apr 2014 00:14:35 +0000 (00:14 +0000)]
feed: unset GIT_DIR and use "git --git-dir=.. log"
This should elimate all of our %ENV dependencies in the WWW portion
of our code.
Eric Wong [Tue, 29 Apr 2014 05:33:45 +0000 (05:33 +0000)]
cgi: mid2blob does not depend on $ENV{GIT_DIR}
ENV changes do not propagate to child processes under mod_perl
Eric Wong [Tue, 29 Apr 2014 05:10:48 +0000 (05:10 +0000)]
implement our own cat-file --batch wrapper
We use --git-dir=... instead of $ENV{GIT_DIR} because ENV changes
do not propagate easily with mod_perl.
Eric Wong [Tue, 29 Apr 2014 03:43:20 +0000 (03:43 +0000)]
config: use "git config --file" to avoid changing %ENV
%ENV changes do not propagate by default under a mod_perl2
environment, and we might as well work towards being thread-safe.
Eric Wong [Mon, 28 Apr 2014 22:09:30 +0000 (22:09 +0000)]
cgi: make CGI optional for Plack users
CGI.pm is on its way out, so do not make it a hard requirement for
Plack users. We still support CGI-only installations because some
sysadmins and distros may be very conservative.
Eric Wong [Mon, 28 Apr 2014 21:46:44 +0000 (21:46 +0000)]
cgi: wrap self_uri calls for Plack::Request
We should be adding automated tests for this, soon.
Eric Wong [Mon, 28 Apr 2014 21:46:04 +0000 (21:46 +0000)]
feed: call URI->as_string explicitly
Implicit string conversion is more confusing.
Eric Wong [Mon, 28 Apr 2014 21:02:41 +0000 (21:02 +0000)]
use relative URLs in HTML index
Browsers know how to follow relative URLs, so we may generate
smaller HTML pages.
Eric Wong [Mon, 28 Apr 2014 20:47:33 +0000 (20:47 +0000)]
cgi: do not decode path_info
We only generate URI-escaped URLs, so we should not be decoding this
into octets.
Eric Wong [Mon, 28 Apr 2014 20:45:42 +0000 (20:45 +0000)]
feed: swap order of "next" and "head" links
This is one less key stroke for somebody paging through the
list history.
Eric Wong [Mon, 28 Apr 2014 20:04:44 +0000 (20:04 +0000)]
feed: avoid redirect on permalink
This saves one round-trip request response so reduces latency over
slow links. The redirect only exists for convenience and isn't 100%
reliable in case the Message-ID terminates with a .(html|txt)
suffix.
Eric Wong [Mon, 28 Apr 2014 10:55:59 +0000 (10:55 +0000)]
feed: dead code elimination around dropped endpoints
public-inbox is for discussion, so top-level posts do not get
special treatment.
Eric Wong [Mon, 28 Apr 2014 10:25:58 +0000 (10:25 +0000)]
mda: support aliased addresses
This mimics functionality found in -learn. Originally the design
allowed for only one address per-list, but when migrating/hijacking
existing mailing lists, having multiple addresses map to the same
inbox is useful.
Eric Wong [Mon, 28 Apr 2014 07:39:41 +0000 (07:39 +0000)]
feed: disable navigation to previous page
This is unfortunately needed for scalability to long histories.
The design of git requires it to traverse full history to walk
forward in time, since commits can only record past history.
Instead, replace "prev" with a "head" link to zip us back to
the most recent page. Users who wish to go backwards can use
browser history, which should always work on our old-fashioned
HTML pages.
Eric Wong [Mon, 28 Apr 2014 03:27:21 +0000 (03:27 +0000)]
feed: pedantically quote HTML attributes
This is more correct, although it costs us 4 bytes.
Eric Wong [Mon, 28 Apr 2014 04:56:47 +0000 (04:56 +0000)]
allow running as a Plack app without CGI emulation
This might be slightly cleaner, though generating the base URL
now has an ugly condition in it.
Eric Wong [Mon, 28 Apr 2014 04:50:17 +0000 (04:50 +0000)]
uri_escape => uri_escape_utf8
We should be able to deal with URIs with non-ASCII characters in
them. I only found this problem when looking at archives with
non-English spam :x
Eric Wong [Mon, 28 Apr 2014 02:15:04 +0000 (02:15 +0000)]
cgi: preliminary Plack compatibility
This needs further testing and refactoring, but seems to work
reasonably well.
Eric Wong [Sun, 27 Apr 2014 06:21:57 +0000 (06:21 +0000)]
feeds use XHTML to avoid tag soup
This should work in most browsers, lets find out!
Eric Wong [Sun, 27 Apr 2014 05:04:02 +0000 (05:04 +0000)]
Feed: <id> element must be a URI, oops :x
For each feed element, we'll just use the link since there's
currently no suitable URN.
Eric Wong [Sun, 27 Apr 2014 01:56:39 +0000 (01:56 +0000)]
view: uri_escape subject
This hopefully improves compatibility with mailers
Eric Wong [Sat, 26 Apr 2014 22:22:35 +0000 (22:22 +0000)]
feed: comment about the %deleted hash
It's strictly not necessary anymore since
commit
fa6168c56bdd1cece178b6b852a9b2cba6ce6ffb
("feed: message must exist in current HEAD to show up")
However it can still save us some unnecessary syscalls and
round-trips to the "git cat-file --batch" process, so it's probably
worth th cost of stuffing it in a hash.
Eric Wong [Sat, 26 Apr 2014 21:32:52 +0000 (21:32 +0000)]
cgi: style: return undef => return
Eric Wong [Sat, 26 Apr 2014 09:07:42 +0000 (09:07 +0000)]
feed: message must exist in current HEAD to show up
We do not want recently-deleted spam showing up when looking
in old histories.
Eric Wong [Sat, 26 Apr 2014 07:42:25 +0000 (07:42 +0000)]
spamassassin rule and config updates
While we're at it, add a script for easy editing of user prefs.
We need some human-maintained rules based on the spam we get.
It's an imperfect world, but I'd _much_ rather deal with the
occassional spam than require signup/registration to post.
Eric Wong [Sat, 26 Apr 2014 02:52:50 +0000 (02:52 +0000)]
view: show References: header, too
Some mail user agents use this header, and Mail::Thread uses
it, too, so show it if possible, but only if it's not redundant
to In-Reply-To.
Eric Wong [Sat, 26 Apr 2014 02:29:22 +0000 (02:29 +0000)]
view: add per-message HTML footer to encourage replies
This may not work with most mail user agents, however.
Eric Wong [Sat, 26 Apr 2014 01:01:10 +0000 (01:01 +0000)]
huge refactor of encoding handling
Hopefully this simplifies and corrects our usage of Perl encoding
APIs.
Eric Wong [Fri, 25 Apr 2014 07:49:14 +0000 (07:49 +0000)]
cgi: eliminate dead/redundant HTML escaping code
Eric Wong [Thu, 24 Apr 2014 00:21:21 +0000 (00:21 +0000)]
html: refactor header value handling to be OO
This helps us keep track of escaping which needs to be done
for various levels.
Eric Wong [Wed, 23 Apr 2014 10:50:08 +0000 (10:50 +0000)]
t/feed: cleanup test and add test for /f/ link
We already depend on IPC::Run, so just use it our tests.
Eric Wong [Wed, 23 Apr 2014 01:05:56 +0000 (01:05 +0000)]
feed: add tests for <id> element setting
We need to ensure this works
This follows commit
bd8fd095067b79a0d2a40bbca2b27b923d02b3f8
("feed: fix address when multiple addresses exist")
Eric Wong [Mon, 21 Apr 2014 20:39:54 +0000 (20:39 +0000)]
t/feed: notify user of missing XML::Feed
One of my dev machines did not have XML::Feed so things were
not tested sufficiently.
Eric Wong [Tue, 22 Apr 2014 09:48:53 +0000 (09:48 +0000)]
view: fix link to raw message from /f/ endpoint
Ugh, at least this has a test...
Eric Wong [Tue, 22 Apr 2014 09:24:45 +0000 (09:24 +0000)]
fix quoted URL generation in feeds
While we're at it, make sure strange characters are escaped properly
in Message-IDs. We'll need tests for all this behavior.
Eric Wong [Tue, 22 Apr 2014 09:22:30 +0000 (09:22 +0000)]
view: do not decode Message-ID
This is ridiculous, nobody (including ssoma) ever does this.
Eric Wong [Mon, 21 Apr 2014 19:29:32 +0000 (19:29 +0000)]
feed: fix address when multiple addresses exist
This needs to be cleaned up
Eric Wong [Mon, 21 Apr 2014 18:33:22 +0000 (18:33 +0000)]
README: add links to try and HTML archives
Eric Wong [Mon, 21 Apr 2014 10:43:59 +0000 (10:43 +0000)]
config: use description file for gitweb
Do not repeat ourselves, just use the same description file
gitweb uses to avoid surprising users.
Eric Wong [Mon, 21 Apr 2014 10:10:14 +0000 (10:10 +0000)]
html/index: fix broken prev/next pagination on short histories
We do not have much history in public-inbox meta, so do
not mislead users with strange navigation elements which
lead nowhere.
Eric Wong [Mon, 21 Apr 2014 10:00:21 +0000 (10:00 +0000)]
feed: there is only one atom feed, with all messages
This is not a blog. All posts, whether replies or not,
carry equal weight.
Eric Wong [Mon, 21 Apr 2014 09:53:53 +0000 (09:53 +0000)]
html/index: do not waste space with non-existent thread roots
Screen real-estate is valuable, and missing roots tend to
be false-positive matches (using Subject, not In-Reply-To
or References).
Eric Wong [Mon, 21 Apr 2014 09:19:13 +0000 (09:19 +0000)]
doc: update design_www and add HACKING file
Document some of the stranger choices I've made.
Eric Wong [Mon, 21 Apr 2014 08:07:53 +0000 (08:07 +0000)]
new scripts for importing slrn spools and maildirs
The old import_gmane_spool script was inflexible,
since we may import from maildir archives as well, so
get everything into maildir, first.
Eric Wong [Mon, 21 Apr 2014 01:45:24 +0000 (01:45 +0000)]
README: fix URL for source code clone
This is an 80x24.org project (more on that at another date).
Eric Wong [Mon, 21 Apr 2014 00:18:33 +0000 (00:18 +0000)]
scripts/dc-dlvr: allow exiting from ~/.dc-dlvr.pre
The ~/.dc-dlvr.pre script for my public-inbox user does this.
Eric Wong [Sun, 20 Apr 2014 23:27:46 +0000 (23:27 +0000)]
use ORIGINAL_RECIPIENT once again
It should be common for a single users to be subscribed to multiple
addresses/lists, so we must use the address before alias expansion.
This partially reverts commit
b949afc9edf89dd494cac6255c78b124d58e11a5