conf: newmail_hook is a remote option
Improve documentation. Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
a1f40af033
commit
14ef992444
@ -295,17 +295,6 @@ remoterepository = RemoteExample
|
|||||||
#postsynchook = notifysync.sh
|
#postsynchook = notifysync.sh
|
||||||
|
|
||||||
|
|
||||||
# This option stands in the [Account Test] section.
|
|
||||||
#
|
|
||||||
# You can specify a newmail hook to execute an external command upon receipt
|
|
||||||
# of new mail in the INBOX.
|
|
||||||
#
|
|
||||||
# This example plays a sound file of your chosing when new mail arrives.
|
|
||||||
#
|
|
||||||
#newmail_hook = lambda: os.system(
|
|
||||||
#"cvlc --play-and-stop --play-and-exit /path/to/sound/file.mp3 > /dev/null 2>&1")
|
|
||||||
|
|
||||||
|
|
||||||
# This option stands in the [Account Test] section.
|
# This option stands in the [Account Test] section.
|
||||||
#
|
#
|
||||||
# The historical backend is 'plain' which writes out the state in plain text
|
# The historical backend is 'plain' which writes out the state in plain text
|
||||||
@ -1130,6 +1119,19 @@ remoteuser = username
|
|||||||
#readonly = False
|
#readonly = False
|
||||||
|
|
||||||
|
|
||||||
|
# This option stands in the [Repository RemoteExample] section.
|
||||||
|
#
|
||||||
|
# You can specify a newmail hook to execute an external command upon receipt
|
||||||
|
# of new mail in the INBOX.
|
||||||
|
#
|
||||||
|
# The pythonfile must be set to import any required library.
|
||||||
|
#
|
||||||
|
# This example plays a sound file of your chosing when new mail arrives.
|
||||||
|
#
|
||||||
|
#newmail_hook = lambda: os.system(
|
||||||
|
#"cvlc --play-and-stop --play-and-exit /path/to/sound/file.mp3 > /dev/null 2>&1")
|
||||||
|
|
||||||
|
|
||||||
[Repository GmailExample]
|
[Repository GmailExample]
|
||||||
|
|
||||||
# A repository using Gmail's IMAP interface.
|
# A repository using Gmail's IMAP interface.
|
||||||
|
@ -883,10 +883,10 @@ class BaseFolder(object):
|
|||||||
for thread in threads:
|
for thread in threads:
|
||||||
thread.join()
|
thread.join()
|
||||||
|
|
||||||
# Execute new mail hook if we have new mail
|
# Execute new mail hook if we have new mail.
|
||||||
if self.have_newmail:
|
if self.have_newmail:
|
||||||
if self.newmail_hook != None:
|
if self.newmail_hook != None:
|
||||||
self.newmail_hook();
|
self.newmail_hook()
|
||||||
|
|
||||||
def __syncmessagesto_delete(self, dstfolder, statusfolder):
|
def __syncmessagesto_delete(self, dstfolder, statusfolder):
|
||||||
"""Pass 2: Remove locally deleted messages on dst.
|
"""Pass 2: Remove locally deleted messages on dst.
|
||||||
|
Loading…
Reference in New Issue
Block a user