From ff861ca314ba1f0ce7593b666a2d946b04ff6620 Mon Sep 17 00:00:00 2001 From: Casper Date: Sat, 22 Feb 2020 00:52:32 +0100 Subject: [PATCH] Allow calling setup.sh from other scripts Calling setup.sh from other scripts fails, for example when adding a new mailbox: the input device is not a TTY --- setup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.sh b/setup.sh index 8f94135d..84a5d4fd 100755 --- a/setup.sh +++ b/setup.sh @@ -127,7 +127,7 @@ _docker_image_exists() { fi } -if [ -t 1 ] ; then +if tty -s ; then USE_TTY="-ti" fi