diff --git a/ChangeLog b/ChangeLog index 1b5bac3..1d4aa10 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,7 @@ huhu 0.11.0 (unreleased) * Re-order and add metadata files (TODO, ChangeLog, ...). * Update to current Debian version. * Add shell to new huhu mod users. +* Add wrapper script for read-mail.pl huhu 0.10 (unknown) * huhu reports version 0.09 (from MOD/Displaylib.pm), but has code diff --git a/bin/read-mail-wrapper.sh b/bin/read-mail-wrapper.sh new file mode 100755 index 0000000..2532992 --- /dev/null +++ b/bin/read-mail-wrapper.sh @@ -0,0 +1,17 @@ +#!/bin/sh +# +# This script is a wrapper for read-mail.pl to set up the environment. +# +# Usage: ${HUHU_DIR}/bin/read-mail-wrapper.sh de.alt.test.moderated + +export "LANG=C" +export "LC_CTYPE=C" +set -o nounset +set -o errexit + +export HUHU_DIR="/home/huhu" +export PERL5LIB="${PERL5LIB:+$PERL5LIB:}${HUHU_DIR}" +USER_DIR=$( echo "$1" | sed 's#[-.]#/#g' ) +CONFIG="/home/${USER_DIR}/etc/public.conf" + +cat - | "${HUHU_DIR}/bin/read-mail.pl" "-config=${CONFIG}" -stdin