summaryrefslogtreecommitdiff
path: root/remoteusage
diff options
context:
space:
mode:
authorTomi Ollila <tomi.ollila@iki.fi>2013-04-02 12:18:20 +0300
committerTomi Ollila <tomi.ollila@iki.fi>2013-04-02 12:18:20 +0300
commit281ac0bd4b50ec4a1a832c688f16361390aaace4 (patch)
treec7a299265c71f4a85f356ccd55b1edf3d75bb179 /remoteusage
parent2c6454c07c4511c38262ee78b8e72ac207da31b5 (diff)
added support for batch count & troubleshooting
Diffstat (limited to 'remoteusage')
-rw-r--r--remoteusage/aboriginal.mdwn4
1 files changed, 3 insertions, 1 deletions
diff --git a/remoteusage/aboriginal.mdwn b/remoteusage/aboriginal.mdwn
index 569b338..e00ed6f 100644
--- a/remoteusage/aboriginal.mdwn
+++ b/remoteusage/aboriginal.mdwn
@@ -20,6 +20,7 @@ Write the following code to a file, for example `remote-notmuch.sh`.
# http://notmuchmail.org/remoteusage/aboriginal/
set -eu
+ #exec 2>>remote-errors; echo -- >&2; set -x # outcomment for debugging
readonly SSH_CONTROL_SOCK='~'/.ssh/master-user@host:22
@@ -29,7 +30,7 @@ Write the following code to a file, for example `remote-notmuch.sh`.
readonly SSH_CONTROL_ARGS='-oControlMaster=no -S '$SSH_CONTROL_SOCK
- if ssh $SSH_CONTROL_ARGS 0.1 $notmuch $ARGS 2>>/dev/null
+ if ssh -q $SSH_CONTROL_ARGS 0.1 $notmuch $ARGS
then exit 0
else ev=$?
fi
@@ -39,6 +40,7 @@ Write the following code to a file, for example `remote-notmuch.sh`.
case $* in
'config get user.primary_email') echo 'nobody@nowhere.invalid'; exit 0 ;;
'config get user.name') echo 'nobody'; exit 0 ;;
+ 'count'*'--batch'*) while read line; do echo 1; done; exit 0 ;;
'count'*) echo 1; exit 0 ;;
'search-tags'*) echo 'errors'; exit 0 ;;
'search'*'--output=tags'*) echo 'errors'; exit 0 ;;