notmuch_run ()
{
if [ $1 = "search" ]; then
- $SSH_BIN $USER@$SSH_HOST $NOTMUCH_REMOTE_BIN $@ | while read line; do
+ $SSH_BIN $USER@$SSH_HOST $NOTMUCH_REMOTE_BIN $@ | while read line; do
sleep 0.1
echo "${line}"
-
done
else
$SSH_BIN $USER@$SSH_HOST $NOTMUCH_REMOTE_BIN $@
scp ${SSH_HOST}:${1} "${FILE_DIR}" > /dev/null 2>&1
retcode="${?}"
if [ "${retcode}" -ne "0" ]; then
- echo "Failed to fetch file" 1>&2
- exit ${retcode}
+ echo "Failed to fetch file" 1>&2
+ exit ${retcode}
fi
}