Enable session logging for imap and and start icedove in background.

$ export NSPR_LOG_MODULES=IMAP:5
$ export NSPR_LOG_FILE=/tmp/thunderbird_`date +%s`.log
$ icedove &

$ less /tmp/thunderbird_1380701130.log
%d bloggers like this: