Help in correct set reverse nametrans

Marcelo Laia marcelolaia at gmail.com
Mon Feb 8 22:57:24 GMT 2016


On 05/02/16 at 12:29am, Nicolas Sebrecht wrote:
>
>First, you might have miss this
>
>  http://offlineimap.org/doc/nametrans.html#createfolders
>


Thank you very much! Finally, I could gpt it work in the latest version, 6.6.1
(I'm a Debian guy). Setting 'createfolders = False' in all Remote Account do
the trick! Thank you very much again.


>  offlineimap --info


I was a offlineimap 6.3.4 version user and the --info arguments appeared in
version v6.4.3 (2012-01-04). So I did a lot off test with offlineimap --info
and got 'offlineimap: error: no such option: --info'. I so sorry. Excuse me for
I have not done a search on the site before posting.


>https://en.wikipedia.org/wiki/Bijection to take the mathematic term.


Very good point here! I don't known it previous!


>Also, while reverse nametrans depends on what you have today, it depends
>on what you could have in the future and what you expect to have. It's
>hard if not impossible to write reverse nametrans for others.


OK! I understand you!


> However, if you give the output of --info you might ask if the
>rules you wrote are correct for the CURRENT folders. Answering to this
>kind of question is more or less easy.


Here you are!

Remote repository 'Gmail-Remote': type 'Gmail'
Host: imap.gmail.com Port: 993 SSL: 1
Establishing connection to imap.gmail.com:993
Server supports ID extension.
Server welcome string: * OK Gimap ready for requests from 186.244.18.77
q15mb46192501uaq
Server capabilities: ('IMAP4REV1', 'UNSELECT', 'IDLE', 'NAMESPACE', 'QUOTA',
'ID', 'XLIST', 'CHILDREN', 'X-GM-EXT-1', 'UIDPLUS', 'COMPRESS=DEFLATE',
'ENABLE', 'MOVE', 'CONDSTORE', 'ESEARCH', 'UTF8=ACCEPT', 'LIST-EXTENDED',
'LIST-STATUS', 'APPENDLIMIT=35882577')

folderfilter= lambda foldername: foldername not in ['.*Spam$', '.*spam$',
'.*Lixeira$', 'Sent Mail', 'Trash']

nametrans= lambda folder: re.sub('.*Rascunhos$', 'Rascunhos',
re.sub('.*E-mails enviados$', 'Enviados',
re.sub('.*Com estrela$', 'Importante',
re.sub('.*Lixeira$', 'Lixeira',
re.sub('INBOX','Inbox', folder)))))

Folderlist:
 [Gmail]/E-mails enviados -> Enviados
 [Gmail]/Com estrela -> Importante
 INBOX -> Inbox
 [Gmail]/Rascunhos -> Rascunhos

Local repository 'Gmail-Local': type 'Maildir'
Folderlist:
 Enviados
 Rascunhos
 Lixeira
 Importante
 Inbox


Thank you very much again!

-- 
Marcelo




More information about the OfflineIMAP-project mailing list