From: Tomi Ollila <domo141@gmail.com>
To: notmuch@notmuchmail.org
Subject: rfc for notmuch remote access script
Date: Thu, 27 Oct 2016 20:25:41 +0300 [thread overview]
Message-ID: <87lgx9ln56.fsf@localhost.localdomain.i-did-not-set--mail-host-address--so-tickle-me> (raw)
Hi
j4ni on irc expressed interest of having an installation option for
notmuch-emacs and a notmuch remote access script as 'notmuch'
This got me thinking what kind of script would fulfill all the needs
that I know of.
and this is the result of that:
--8<----8<----8<----8<----8<----8<----8<----8<--
#!/bin/bash
set -euf
if [ "${NOTMUCH_REMOTE_XTRACE_FILE-}" ]; then
exec 6>>"$NOTMUCH_REMOTE_XTRACE_FILE"
BASH_XTRACEFD=6
echo -- >&6
set -x
env >&6
fi
: ${NOTMUCH_REMOTE_SSH_COMMAND:=ssh}
: ${NOTMUCH_REMOTE_SSH_ARGS=}
: ${NOTMUCH_REMOTE_HOST:=notmuch}
: ${NOTMUCH_REMOTE_COMMAND:=notmuch}
printf -v ARGS '%q ' "$@"
exec "$NOTMUCH_REMOTE_SSH_COMMAND" $NOTMUCH_REMOTE_SSH_ARGS \
"$NOTMUCH_REMOTE_HOST" $NOTMUCH_REMOTE_COMMAND $ARGS
--8<----8<----8<----8<----8<----8<----8<----8<--
out of the box this works like the instructions given in
https://notmuchmail.org/remoteusage/ (with ~/.ssh/config changes)
and https://notmuchmail.org/remoteusage/124/ (with suitable wrapping
so that contents of ~/.ssh/ can be left unmodified)
also, debugging is easy. (setenv "NOTMUCH_REMOTE_XTRACE_FILE" "xtrace.log")
inside emacs, and NOTMUCH_REMOTE_XTRACE_FILE=xtrace.log notmuch-remote
on the command line.
what do you think?
Tomi
next reply other threads:[~2016-10-27 17:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-27 17:25 Tomi Ollila [this message]
2016-10-27 21:37 ` rfc for notmuch remote access script Matt Armstrong
2016-10-30 21:31 ` Tomi Ollila
2016-10-28 6:42 ` Jani Nikula
2016-10-28 10:35 ` David Bremner
2016-10-30 9:35 ` Jani Nikula
2016-10-30 11:34 ` David Bremner
2016-10-30 12:39 ` Mark Walters
2016-10-30 14:36 ` Jani Nikula
2016-10-30 15:52 ` David Bremner
2016-11-04 18:54 ` Jani Nikula
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lgx9ln56.fsf@localhost.localdomain.i-did-not-set--mail-host-address--so-tickle-me \
--to=domo141@gmail.com \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).