Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cubicweb
cubes
email
Commits
27c3aa98583a
Commit
d89695c1
authored
Oct 05, 2010
by
Sylvain Thénault
Browse files
cleanup
--HG-- branch : stable
parent
416a661115b7
Changes
2
Hide whitespace changes
Inline
Side-by-side
ccplugin.py
View file @
27c3aa98
"""cubicweb-ctl plugin providing the mboximport command
:organization: Logilab
:copyright: 2007-200
9
LOGILAB S.A. (Paris, FRANCE), all rights reserved.
:copyright: 2007-20
1
0 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
:contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
"""
__docformat__
=
"restructuredtext en"
...
...
mboximport.py
View file @
27c3aa98
"""import an mbox or a single email into an cubicweb application
:organization: Logilab
:copyright: 2007-200
8
LOGILAB S.A. (Paris, FRANCE), all rights reserved.
:copyright: 2007-20
1
0 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
:contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
"""
__docformat__
=
"restructuredtext en"
...
...
@@ -180,8 +180,6 @@ class MBOXImporter(object):
if
name
or
main
!=
'text'
and
contenttype
!=
'application/pgp-signature'
:
# suppose if we have a name, this is an attachement else this is a
# part/alternative
if
not
name
and
main
!=
'text'
:
print
'duh'
,
main
,
sub
name
=
name
or
u
'no name'
if
isinstance
(
data
,
unicode
):
data
=
data
.
encode
(
'utf8'
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment