diff options
author | Xiao Pan <xyz@flylightning.xyz> | 2024-07-19 16:23:04 -0700 |
---|---|---|
committer | Xiao Pan <xyz@flylightning.xyz> | 2024-07-19 16:23:04 -0700 |
commit | d15576c4592b9db52b0c6441116eb57439b4b92c (patch) | |
tree | f2bfdd3077c27363960955db107b9339e273d9c1 /home/xyz/.config | |
parent | dc9a5212de9a0f121d16617f913196298615e5d3 (diff) |
neomutt wrapper scrip to mbsync before and after
Diffstat (limited to 'home/xyz/.config')
-rw-r--r-- | home/xyz/.config/neomutt/neomuttrc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/home/xyz/.config/neomutt/neomuttrc b/home/xyz/.config/neomutt/neomuttrc index f4d88ff6..7c8d6b81 100644 --- a/home/xyz/.config/neomutt/neomuttrc +++ b/home/xyz/.config/neomutt/neomuttrc @@ -91,6 +91,19 @@ set mail_check=60 # no ask auto save to draft set postpone='yes' +# need echo here to run an external shell command, see https://neomutt.org/feature/global-hooks +# startup-hook works, but I'm not confidient with it because shutdown-hook is buggy, see below. Because I'll need a wrapper script for mbsync after shutdown, I decided to just use a wrapper script for mbsync before startup also for now +#startup-hook 'echo `mbsync -a`' +# I decided not to use timeout-hook and shutdown-hook hooks due to its issues with mbsync, see below +# timeout-hook and shutdown-hook configured with startup-hook will cause timeout-hook and shutdown-hook mbsync not working? see https://github.com/neomutt/neomutt/issues/3298 , my experience is shutdown-hook's mbsync not working, not sure how to test timeout-hook +# somehow `sleep 1; mbsync -a` works? +# maybe related: https://github.com/neomutt/neomutt/issues/4184 https://github.com/neomutt/neomutt/pull/4200 +# more bug notes see vq +# consider I may use another email client to access remote email mailboxes, sync when shutdown so those other email client can get latest changes +#shutdown-hook 'echo `mbsync -a`' +# I don't understand timeout-hook and $timeout very well, but seems useful, $timeout default 600 seconds, so maybe it sync every 600s +#timeout-hook 'echo `mbsync -a`' + set query_command="abook --mutt-query '%s'" # https://neomutt.org/guide/advancedusage#8-%C2%A0external-address-queries # completion when ask for address input |