diff options
Diffstat (limited to 'notmuch-tcp')
-rwxr-xr-x | notmuch-tcp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/notmuch-tcp b/notmuch-tcp new file mode 100755 index 0000000..71680d0 --- /dev/null +++ b/notmuch-tcp | |||
@@ -0,0 +1,9 @@ | |||
1 | #!@zsh@/bin/zsh | ||
2 | |||
3 | NOTMUCH_TCP=${NOTMUCH_TCP:-2010} | ||
4 | HOST=${HOST:-$(@nettools/bin/hostname -s)} | ||
5 | NOTMUCH_HOST=${NOTMUCH_HOST:-odin.asgard.yggdrasil} | ||
6 | |||
7 | cd ~/.notmuch-tcp | ||
8 | |||
9 | @socat@/bin/socat STDIO,ignoreeof openssl:${NOTMUCH_HOST}:${NOTMUCH_TCP},verify=1,cafile=ca.pem,certificate=${HOST}.pem,key=${HOST}.key <<(print "${(@q)@}"; inp=$(cat); printf "%d\n" $(wc -c <<<"${inp}"); cat <<<"${inp}") | ||