Commit Graph

1933 Commits

Author SHA1 Message Date
Łukasz Żarnowiecki 1fb8ba9631 Rename email.Parser to email.parser
Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-10 02:53:09 +02:00
Łukasz Żarnowiecki b5d9652bc9 Do not mix tabs with spaces
Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-10 02:53:09 +02:00
Łukasz Żarnowiecki c327bec6c8 Convert except X,T to except X as T
Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-10 02:53:08 +02:00
Łukasz Żarnowiecki 6b8ee4a183 Handle maxage for davmail correctly
"imapobj.search" returns a list with one string element of numbers
separated by one whitespace character for regular box (GMail, AOL...).
['1 2 3 4 5 6 7 8 9 10 11 12']
But if we would like to sync from Davmail it would return a list of
numbers.
['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12'].

The code "return res_data[0].split()" in the first case will return what
we already have when using Davmail, hence only one email will be
fetched.  But if only the first sync would be with maxage the emails
will be removed, because offlineimap will think that they were removed
by us.

The patch distinguishes between syncing with Davmail and regular box and
applies split on the first element only when it finds whitespace
character.  It also handles the case when the first element is empty on
first sync.

Closes #327

Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-07 13:29:44 +02:00
Łukasz Żarnowiecki 4119aeda7d Add tags to gitignore
Used by vim, could be generated by ctags program.

Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-05 23:50:24 +02:00
Łukasz Żarnowiecki 92e5455eb4 Inform when maxage/startdate is in the future
Sometimes it might happen that you put wrong date and you except emails
to be fetched, but they are not and you do not have an idea why.

By raising exception the user will see a proper message telling that he
used the wrong date for maxage/startdate property.

If someone wants to set a future date intentionally might as well sync
in the future.

Signed-off-by: Łukasz Żarnowiecki <dolohow@outlook.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-05-05 23:50:24 +02:00
Nicolas Sebrecht 141abfdf50 don't write a pid file
This was likely used to avoid multiple instances but this is supported for
several years.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-26 23:49:45 +02:00
Nicolas Sebrecht 2fb2f840dc XOAUTH2: don't force oauth2_request_url to be defined
Not all users want XOAUTH2.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-25 18:38:31 +02:00
Nicolas Sebrecht be940f3784 offlineimap.conf: XOAUTH2: expose and document the oauth2_request_url option
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-25 18:10:07 +02:00
Nicolas Sebrecht 2fc5d2a814 XOAUTH2: raise error when oauth_request_url is missing for IMAP type
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-25 17:38:42 +02:00
Nicolas Sebrecht 7b4c47ab4e offlineimap.conf: improve documentation for oauth2
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-23 16:38:29 +02:00
Nicolas Sebrecht 1c04823453 sync_deletes option is now tested
Improve documentation.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-19 19:13:55 +02:00
Nicolas Sebrecht c00470af03 manual: improve rendering
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-11 13:22:54 +02:00
Nicolas Sebrecht 6505cdf957 manual: improve sqlite section
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-11 13:22:25 +02:00
Nicolas Sebrecht d5853b5d65 learn to not delete messages
This enables the "append" mode feature. Configuration option is sync_deletes in
both local and remote repositories. Marked EXPERIMENTAL and UNTESTED.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 22:08:28 +02:00
Nicolas Sebrecht 41e275e9a2 make sqlite status cache the default
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 21:06:38 +02:00
Nicolas Sebrecht 6fb5700f94 SQLite: close db when done
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 19:55:26 +02:00
Nicolas Sebrecht 1ba5e9160d minor: logs: print readonly message in all debug modes
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 18:57:00 +02:00
Nicolas Sebrecht 801dda521e accounts.py: minor improvements
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 18:50:12 +02:00
Nicolas Sebrecht 657f258196 folder: properly factorize initialization and dropping of self.message
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 18:12:18 +02:00
Nicolas Sebrecht 9486a0dab3 IMAP: don't try to create empty folders
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-04-09 17:35:15 +02:00
Om Prakash 7790a6ae6c offlineimap.txt:minor typo fixes
Signed-off-by: Om Prakash Kumar <omprakash070@gmail.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-23 23:12:26 +01:00
Dodji Seketeli ccb3bc3819 Really execute the recipe of the 'docs' target in top-most Makefile
Make the 'docs' target be a PHONY one so that its recipe gets executed
even though there is a directory named 'docs' too.

Signed-off-by: Dodji Seketeli <dodji@seketeli.org>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-21 18:41:41 +01:00
Nicolas Sebrecht 8c7a7355a3 v6.7.0
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-10 17:08:18 +01:00
Nicolas Sebrecht 15efea24b9 .github/: improve templates
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-09 09:35:59 +01:00
Nicolas Sebrecht 8ed4f35fc8 introduce a code of conduct
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-07 13:36:33 +01:00
Ilias Tsitsimpis c84d23b656 Identify and fix messages with FMD5 inconsistencies
Introduce the '--migrate-fmd5-using-nametrans' option which migrates the
FMD5 hashes from versions prior to 6.3.5.

It seems that commit 'Apply nametrans to all Foldertypes' (6b2ec956cf)
introduced a regression because it changed the FMD5 part of the filename
calculated by OfflineIMAP. Thus, OfflineIMAP believes that the messages
has been removed and adds them back.

For more information, see:
http://www.offlineimap.org/configuration/2016/02/12/debian-upgrade-from-jessie-to-stretch.html

Bug-Debian: https://bugs.debian.org/812108
Reported-by: François <francois@avalenn.eu>
Signed-off-by: Ilias Tsitsimpis <i.tsitsimpis@gmail.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-06 21:01:51 +01:00
Nicolas Sebrecht 334571038e minor improvement of github issue template
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-06 21:01:13 +01:00
Nicolas Sebrecht 2f541e4872 release.sh: move the authors section up
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-05 14:36:54 +01:00
Ben Boeckel d8398ba374 Curses, UIBase: remove references to __bigversion__
__bigversion__ was removed in 281bcefb52.

Signed-off-by: Ben Boeckel <mathstuf@gmail.com>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-05 06:47:24 +01:00
Nicolas Sebrecht 29a7dbd51b sphinx doc: remove usage of __bigversion__
Fix regression introduced by 281bcef.

Reported-by: mathstuf
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-04 22:33:16 +01:00
Nicolas Sebrecht 06881f9a71 README: add slogan
Thanks-to: Norbert Preining
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-03-02 15:36:22 +01:00
Nicolas Sebrecht 3b249dad14 Merge branch 'ns/github' into next 2016-02-28 19:01:37 +01:00
Nicolas Sebrecht 90afb1b338 add github templates
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-28 18:59:10 +01:00
Nicolas Sebrecht 8b661eb58e MAINTAINERS: update
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-27 20:10:34 +01:00
Nicolas Sebrecht f0a585b02f release.sh: add pypi instructions
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-27 05:35:09 +01:00
Nicolas Sebrecht c549af78eb pypi requires a setup.cfg when README is Markdown
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-27 05:34:46 +01:00
Nicolas Sebrecht 543890e257 MANIFEST: exclude rfcs
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-27 05:25:09 +01:00
Nicolas Sebrecht 07b6c895c5 release.sh: improve release annoucements
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-23 11:18:10 +01:00
Nicolas Sebrecht 208f555230 Merge branch 'earies-ipv6' into next 2016-02-23 07:11:25 +01:00
Nicolas Sebrecht e51b828013 add documentation for the ipv6 configuration option
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-23 07:09:53 +01:00
Ebben Aries 9bfd610230 change hard coding of AF_UNSPEC to user-defined address-families per repository
Some environments that return AAAA records for their IMAP servers can pose
problems for clients that do not have end-to-end IPv6 connectivity for a number
of reasons (e.g. policy, lack of full routing, security, etc..)

Even with a fallback mechanism in place, you can still arrive at IMAP
implementations that could prevent authentication from unknown IPv6 space. This
in itself is not enough to fallback to IPv4 since there is an actual connection
on that socket.

This change is for introducing a user-defined value:

  [Repository imap-remote]
  ipv6 = no

to create a preference per repository on which AF to connect to the remote
server on

ipv6 = yes (AF_INET6)
ipv6 = no (AF_INET)
unspecified = default

Signed-off-by: Ebben Aries <e@dscp.org>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-23 06:57:21 +01:00
Nicolas Sebrecht 8f94ef1973 release: add command to install from pip in the announces
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-22 13:04:16 +01:00
Nicolas Sebrecht b0cf523ba7 Changelog: fix typo
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-22 12:48:18 +01:00
Nicolas Sebrecht 893a90c291 v6.7.0-rc2
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-22 12:47:42 +01:00
Nicolas Sebrecht 9fe337d4fb fix year of copyright
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-22 12:24:15 +01:00
Nicolas Sebrecht 281bcefb52 versioning: avoid confusing pip by spliting out __version__ with __revision__
Python tools are not used to a __revision__.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-22 12:14:49 +01:00
Nicolas Sebrecht 36375daee6 fix: exceptions.OSError might not have attribute EEXIST defined
Since this is used in an except calse, we first don't mask the real cause and
raise the original error.

Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-19 12:33:57 +01:00
Nicolas Sebrecht 36165e391f update links to the new URL www.offlineimap.org
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-19 12:10:23 +01:00
Ray Song b670bb2022 XOAUTH2 handler: urlopen with proxied socket
Signed-off-by: Ray Song <i@maskray.me>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
2016-02-15 11:14:50 +01:00