

NoPriv.py - Easy IMAP email backup to HTML archive - mdewinter
https://raymii.org/s/software/Nopriv.py.html

======
andrewcooke
is this a good idea? shouldn't backups be in a _standard_ format (for the
medium in question)? what if i want to import emails from this _backup_ into
another mail program / mail provider?

it seems like a useful static(?) _interface_ to email, but as a _backup_ it's
oddly restrictive.

maybe it's just confusion over the use of the word "backup". but for me, a
tarball of maildirs, while not readable by a human, is closer to what i expect
that to mean. perhaps this could be modified to provide both?

~~~
dbaupp
Not only does it generate a non-standard format, the HTML has significant
problems:

\- It would be relatively hard to reconstruct the email with a script, e.g.
the headers are formatted as a plain text with <strong> for the labels, the
data left unmarked in anyway and <br> for line breaks (no ids or classes at
all). From <http://sparklingnetwork.nl/nopriv/2012/12/26.html>:

    
    
        <strong>From:</strong> "Remy van Elst &lt;relstnl@gmail.com&gt;"
        <br />
        <strong>To: </strong>""backup@sparklingnetwork.nl" &lt;backup@sparklingnetwork.nl&gt;"
        <br />
    

\- It's invalid markup[1], with the email's HTML contents inserted wholesale,
including the <head> and <body> tags.

\- Not sure if this is a problem with NoPriv.py, or if it has occured earlier
in the chain, but something has screwed up character encodings, e.g. in the
URLs here: <http://sparklingnetwork.nl/nopriv/2012/12/1.html> (The page is
served with no encoding specified nor is there a <meta http-equiv> so it
defaults to UTF-8, and these characters are invalid. However, even in Latin-1
or anything else, they are definitely not '=' which appears to be what they
should be.)

(The markup is also horrible, with strange indentations and a lot of
extraneous whitespace and one-cell tables.)

[1]:
[http://validator.w3.org/check?uri=http%3A%2F%2Fsparklingnetw...](http://validator.w3.org/check?uri=http%3A%2F%2Fsparklingnetwork.nl%2Fnopriv%2F2012%2F12%2F26.html&doctype=HTML5)

~~~
thorum
Simple enough issues to fix, of course, since this project is open source and
only 431 lines of Python.

<https://github.com/RaymiiOrg/NoPriv/blob/master/nopriv.py>

