Gmail folders always deleted/re-downloaded NOT synced?
Tom Marble
tmarble at info9.net
Sun Jun 1 17:16:16 BST 2014
On 06/01/2014 11:03 AM, Eygene Ryabinkin wrote:
> Can you show the full configuration (excluding usernames/passwords) that I will
> be able to reproduce your problem?
Sure... here it is.
--Tom
tmarble at ficelle 102 :) more .offlineimap.py .offlineimaprc
::::::::::::::
.offlineimap.py
::::::::::::::
#
# .offlineimap.py
import re
import functools
def f_or(a, b):
return a or b
def tom_folderfilter(folder):
ic = ['Breck']
return functools.reduce(f_or, [folder.find(x) >= 0 for x in ic])
def tom_nametrans(folder):
return re.sub(r' ', r'_', re.sub('\[Gmail\]', r'Gmail', folder))
def tom_reverse_nametrans(folder):
return re.sub(r'_', r' ', re.sub(r'Gmail', '[Gmail]', folder))
::::::::::::::
.offlineimaprc
::::::::::::::
# -*- Mode: conf; coding: utf-8 -*-
# .offlineimaprc
[general]
accounts = tmarble at info9.net
pythonfile=~/.offlineimap.py
[Account tmarble at info9.net]
localrepository = local-info9.net
remoterepository = remote-info9.net
[Repository local-info9.net]
type = Maildir
localfolders = ~/Private/Mail/info9.net
# nametrans = tom_reverse_nametrans
[Repository remote-info9.net]
type = Gmail
ssl = yes
maxconnections=1
remoteuser = tmarble at info9.net
realdelete = no
maxage = 90
readonly = true
# autorefresh = 10
quick = -1
folderfilter = tom_folderfilter
nametrans = tom_nametrans
sslcacertfile = /etc/ssl/certs/ca-certificates.crt
tmarble at ficelle 103 :)
More information about the OfflineIMAP-project
mailing list