From e30c3354948024bd75a57409441507b1384226b4 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Sun, 24 Sep 2017 14:56:03 +0200 Subject: offlineimap: Delegate mu index update to emacs if `mu` fails When mu4e is in a context, the `mu index` postsynchook doesn't work. Since it returns an exit code, tell Emacs to update the index with the already running `mu` server instance. --- offlineimap/.offlineimaprc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'offlineimap/.offlineimaprc') diff --git a/offlineimap/.offlineimaprc b/offlineimap/.offlineimaprc index c1c4e37..db9bffb 100644 --- a/offlineimap/.offlineimaprc +++ b/offlineimap/.offlineimaprc @@ -10,7 +10,7 @@ localrepository = alanpearce.eu-local remoterepository = alanpearce.eu-remote autorefresh = 5 quick = 2 -postsynchook = mu index --muhome=~/.cache/mu/alanpearce.eu --maildir=%(alanpearcemaildir)s --lazy-check --nocleanup --quiet +postsynchook = mu index --muhome=~/.cache/mu/alanpearce.eu --maildir=%(alanpearcemaildir)s --lazy-check --nocleanup --quiet || emacsclient -e "(mu4e-update-index)" [Repository alanpearce.eu-local] # OfflineIMAP supports Maildir, GmailMaildir, and IMAP for local repositories. @@ -35,7 +35,7 @@ localrepository = riseup.net-local remoterepository = riseup.net-remote autorefresh = 10 quick = 2 -postsynchook = mu index --muhome=~/.cache/mu/riseup.net --maildir=%(riseupmaildir)s --lazy-check --nocleanup --quiet +postsynchook = mu index --muhome=~/.cache/mu/riseup.net --maildir=%(riseupmaildir)s --lazy-check --nocleanup --quiet || emacsclient -e "(mu4e-update-index)" [Repository riseup.net-local] type = Maildir @@ -57,7 +57,7 @@ localrepository = satoshipay.io-local remoterepository = satoshipay.io-remote autorefresh = 5 quick = 2 -postsynchook = mu index --muhome=~/.cache/mu/satoshipay.io --maildir=%(satoshipaymaildir)s --lazy-check --nocleanup --quiet +postsynchook = mu index --muhome=~/.cache/mu/satoshipay.io --maildir=%(satoshipaymaildir)s --lazy-check --nocleanup --quiet || emacsclient -e "(mu4e-update-index)" [Repository satoshipay.io-local] type = GmailMaildir -- cgit 1.4.1