summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorJannis M. Hoffmann <jannis@fehcom.de>2023-09-10 15:39:25 +0200
committerJannis M. Hoffmann <jannis@fehcom.de>2023-09-10 15:39:25 +0200
commit278b76fabf31abe8fc4fbe6ca1c0ad6af830fcb7 (patch)
treea3ca8baafd3c26b6d8df3840fe92f5e2f2dd0c34 /configure
parent84186e77461ddeb867fa2944dcbf45217b41b80e (diff)
added test pam to replace MockMaildir ReadMail implementation
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure13
1 files changed, 1 insertions, 12 deletions
diff --git a/configure b/configure
index b32a319..536e088 100755
--- a/configure
+++ b/configure
@@ -41,13 +41,10 @@ check_ninja_version () {
}
allargs="$*"
-while getopts 'c:e:hm:n:r:u:' opt
+while getopts 'c:e:hm:' opt
do case $opt in
(e) JWM_MAILDIR_EXTRACTOR="$OPTARG";;
- (r) JWM_READ_MODEL="$OPTARG";;
(m) JWM_MODE="$OPTARG";;
- (n) JWM_SENDMAIL="$OPTARG";;
- (u) JWM_USER="$OPTARG";;
(c) JWM_LOGIN_SCHEME="$OPTARG";;
(h)
t="$(printf '\t')"
@@ -57,11 +54,8 @@ usage: $0 configure [options...]
OPTIONS
FLAG ARGUMENT DEFAULT VALUES DESCRIPTION
-e MAILDIR_EXTRACTOR extractpy {extractpy,extractpl,extractrs}
- -r PERL_MODULE JWebmail::Model::ReadMails::MockMaildir The read model implementation
-m MODE development {development,production}
- -u USERNAME $USER $t The server runs as this user
-c LOGIN_SCHEME plain {plain,cram_md5} The login scheme (don't use plain unless over TLS)
- -n PATH sendmail The path to a sendmail executable
END
exit
;;
@@ -71,11 +65,8 @@ done
shift $((OPTIND-1))
: "${JWM_MAILDIR_EXTRACTOR=extractpy}" && echo "$JWM_MAILDIR_EXTRACTOR" | grep -Eq '^extract(pl|py|rs)$'
-: "${JWM_READ_MODEL=JWebmail::Model::ReadMails::MockMaildir}"
: "${JWM_MODE=development}" && [ "$JWM_MODE" = development -o "$JWM_MODE" = production ]
-: "${JWM_USER=$USER}" && id "$JWM_USER" >/dev/null
: "${JWM_LOGIN_SCHEME=plain}" && [ "$JWM_LOGIN_SCHEME" = plain -o "$JWM_LOGIN_SCHEME" = cram_md5 ]
-: "${JWM_SENDMAIL=sendmail}" && [ -x "$(command -v "$JWM_SENDMAIL")" ]
PATH="$(pwd)/node_modules/.bin${PATH:+:$PATH}"
@@ -120,13 +111,11 @@ case "$JWM_MAILDIR_EXTRACTOR" in
;;
esac
-export SENDMAIL="$JWM_SENDMAIL"
export LOGIN_SCHEME="$JWM_LOGIN_SCHEME"
export CONFARGS="$allargs"
export MAILDIR_EXTRACTOR_NAME="$JWM_MAILDIR_EXTRACTOR"
export MAILDIR_EXTRACTOR_BIN
export JWM_EXTRACTRS_DIR
-export JWM_READ_MODEL
export JWM_MODE
perl -pe 's/@(\w+)@/$ENV{$1}/ga' lib/JWebmail/Config.pm.in >|lib/JWebmail/Config.pm