using more than one nametrans in offlineimaprc
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
I'm using offlineimap with gmail and mutt and am very satisfied. It just
works, and most importantly it does something that I couldn't really find
anything else to do reliably. Thanks. My question is this. Gmail gives their
folders some stupid names, "[Gmail]/Sent Mail" and "[Gmail]/Drafts". Using
nametrans in offlinimaprc I want to make those "Sent" and "Drafts". I'm not
very familiar with python and I'm not a real expert with regex. This is what
I have in offlinimaprc:
nametrans = lambda foldername:
re.sub('^\[Gmail\]/Drafts','Drafts',foldername)
nametrans = lambda foldername: re.sub('^\[Gmail\]/Sent\
Mail','Sent',foldername)
The problem is that the second "nametrans =" statement simply overrides the
first so that the drafts folder stays as it is. How do I combine these two
into one statement? thanks
james
- using more than one nametrans in offlineimaprc,
James Smith <=
|
|