MLMMJ archive mid

mlmmj-archive-mid
Login

mlmmj-archive-mid

A Message-ID to archive URL resolver for mlmmj mailing lists.

Given a Message-ID, mlmmj-archive-mid looks it up in mlmmj archive SQLite databases and returns the corresponding archive URL.

It operates in two modes:

Requirements

Building

make

Environment Variables

MLMMJ_ARCHIVES_DIRECTORY Path to the directory containing mailing list archives. Each subdirectory should contain a .db SQLite database with a "mails" table. Required in CGI mode.

MLMMJ_ARCHIVES_PREFIX URL prefix prepended to generated archive paths. Defaults to empty.

CLI Usage

mlmmj-archive-mid -d <archivedir> -m <msgid> [-r]

-d <archivedir>   Path to the archive directory.
-m <msgid>        The Message-ID to look up.
-r                Return the raw text URL instead of HTML.

CGI Usage

The CGI exposes two endpoints:

/mid/<Message-ID>      Redirects to the HTML archive page.
/midraw/<Message-ID>   Redirects to the raw text version.

License

BSD 2-Clause. See the source file for details.