mirror of
https://github.com/imapsync/imapsync.git
synced 2025-06-05 12:17:16 +02:00
1.194
This commit is contained in:
parent
ff7c4df85f
commit
7cc7cb246a
10 changed files with 135 additions and 41 deletions
26
CREDITS
26
CREDITS
|
@ -1,7 +1,33 @@
|
||||||
#!/bin/cat
|
#!/bin/cat
|
||||||
|
|
||||||
|
If you want to make a donation to the author, Gilles LAMIRAL,
|
||||||
|
you can use the imapsync wishlist :
|
||||||
|
http://www.amazon.com/gp/registry/wishlist/1C9UNDIH3P7R7/
|
||||||
|
(Use the lowest postal cost)
|
||||||
|
|
||||||
I thank very much all of these people.
|
I thank very much all of these people.
|
||||||
|
|
||||||
|
Daniel Ammann
|
||||||
|
Made me finally write the --folderrec option.
|
||||||
|
|
||||||
|
Nicola De Marco
|
||||||
|
Had authenticate problems with PLAIN
|
||||||
|
and gave me a donation with the imapsync wishlist.
|
||||||
|
|
||||||
|
Arunav Mandal
|
||||||
|
Success ?
|
||||||
|
from Domino IMAP4 Server Release 7.0.2
|
||||||
|
to Scalix IMAP server 10.0.1.3
|
||||||
|
|
||||||
|
Eric Yellin
|
||||||
|
Failure from Imail 7.04 (not sure)
|
||||||
|
|
||||||
|
Barry W. Hickey
|
||||||
|
Success from Microsoft Exchange 5.5 to Zimbra 4.0.4
|
||||||
|
|
||||||
|
Damjan Perenic
|
||||||
|
Success from cyrus to notes.
|
||||||
|
|
||||||
Tom Allison
|
Tom Allison
|
||||||
Had problem with dovecot and dbmail
|
Had problem with dovecot and dbmail
|
||||||
Message-Id Message-ID. So imapsync is
|
Message-Id Message-ID. So imapsync is
|
||||||
|
|
26
ChangeLog
26
ChangeLog
|
@ -1,17 +1,35 @@
|
||||||
|
|
||||||
RCS file: RCS/imapsync,v
|
RCS file: RCS/imapsync,v
|
||||||
Working file: imapsync
|
Working file: imapsync
|
||||||
head: 1.190
|
head: 1.194
|
||||||
branch:
|
branch:
|
||||||
locks: strict
|
locks: strict
|
||||||
gilles: 1.190
|
|
||||||
access list:
|
access list:
|
||||||
symbolic names:
|
symbolic names:
|
||||||
keyword substitution: kv
|
keyword substitution: kv
|
||||||
total revisions: 190; selected revisions: 190
|
total revisions: 194; selected revisions: 194
|
||||||
description:
|
description:
|
||||||
----------------------------
|
----------------------------
|
||||||
revision 1.190 locked by: gilles;
|
revision 1.194
|
||||||
|
date: 2006/12/08 04:04:34; author: gilles; state: Exp; lines: +22 -12
|
||||||
|
Added --folderrec option
|
||||||
|
Now --folder --subscribed and --folderrec can be
|
||||||
|
used simultaneously.
|
||||||
|
----------------------------
|
||||||
|
revision 1.193
|
||||||
|
date: 2006/12/08 03:29:14; author: gilles; state: Exp; lines: +8 -8
|
||||||
|
Replace PLAIN with LOGIN
|
||||||
|
----------------------------
|
||||||
|
revision 1.192
|
||||||
|
date: 2006/12/04 13:57:45; author: gilles; state: Exp; lines: +10 -9
|
||||||
|
Added imap server releases
|
||||||
|
----------------------------
|
||||||
|
revision 1.191
|
||||||
|
date: 2006/11/11 22:11:25; author: gilles; state: Exp; lines: +7 -7
|
||||||
|
imap servers section
|
||||||
|
DBMail 2.2rc1
|
||||||
|
----------------------------
|
||||||
|
revision 1.190
|
||||||
date: 2006/11/11 00:13:15; author: gilles; state: Exp; lines: +10 -6
|
date: 2006/11/11 00:13:15; author: gilles; state: Exp; lines: +10 -6
|
||||||
Be case inseitive with header keywords.
|
Be case inseitive with header keywords.
|
||||||
----------------------------
|
----------------------------
|
||||||
|
|
7
FAQ
7
FAQ
|
@ -335,10 +335,15 @@ Q. I need to migrate 1250 mailboxes from one cyrus-IMAP server to another
|
||||||
(empty) one. (Box-swap). The passwords are in a MySQL Database.
|
(empty) one. (Box-swap). The passwords are in a MySQL Database.
|
||||||
Can you tell me if your script suits my needs?
|
Can you tell me if your script suits my needs?
|
||||||
|
|
||||||
Partially, mailboxes must exist before running imapsync.
|
R. Partially, mailboxes must exist before running imapsync.
|
||||||
May be, Box-swap is not listed in "Failure stories"
|
May be, Box-swap is not listed in "Failure stories"
|
||||||
nor "Success stories" in the README file.
|
nor "Success stories" in the README file.
|
||||||
You have to extract user and password in a csv file.
|
You have to extract user and password in a csv file.
|
||||||
See the "HUGE MIGRATION" section in the README file.
|
See the "HUGE MIGRATION" section in the README file.
|
||||||
|
|
||||||
|
======================================================================
|
||||||
|
Q. From Cyrus to Notes
|
||||||
|
|
||||||
|
Juhu! --useheader 'Message-ID' --skipsize does wonders! :)
|
||||||
|
|
||||||
|
|
||||||
|
|
18
README
18
README
|
@ -3,7 +3,7 @@ NAME
|
||||||
Synchronise mailboxes between two imap servers. Good at IMAP migration.
|
Synchronise mailboxes between two imap servers. Good at IMAP migration.
|
||||||
More than 25 different IMAP server softwares supported with success.
|
More than 25 different IMAP server softwares supported with success.
|
||||||
|
|
||||||
$Revision: 1.190 $
|
$Revision: 1.194 $
|
||||||
|
|
||||||
INSTALL
|
INSTALL
|
||||||
imapsync works fine under any Unix OS.
|
imapsync works fine under any Unix OS.
|
||||||
|
@ -37,6 +37,7 @@ SYNOPSIS
|
||||||
[--authmech1 <string>] [--authmech2 <string>]
|
[--authmech1 <string>] [--authmech2 <string>]
|
||||||
[--noauthmd5]
|
[--noauthmd5]
|
||||||
[--folder <string> --folder <string> ...]
|
[--folder <string> --folder <string> ...]
|
||||||
|
[--folderrec <string> --folderrec <string> ...]
|
||||||
[--include <regex>] [--exclude <regex>]
|
[--include <regex>] [--exclude <regex>]
|
||||||
[--prefix2 <string>] [--prefix1 <string>]
|
[--prefix2 <string>] [--prefix1 <string>]
|
||||||
[--regextrans2 <regex> --regextrans2 <regex> ...]
|
[--regextrans2 <regex> --regextrans2 <regex> ...]
|
||||||
|
@ -187,6 +188,7 @@ IMAP SERVERS
|
||||||
- DBMail 2.0.7 (GPL). But DBMail 1.2.1 works.
|
- DBMail 2.0.7 (GPL). But DBMail 1.2.1 works.
|
||||||
Patient and confident testers are welcome.
|
Patient and confident testers are welcome.
|
||||||
- dkimap4 2.39
|
- dkimap4 2.39
|
||||||
|
- Imail 7.04 (maybe).
|
||||||
|
|
||||||
Success stories reported with the following imap servers (softwares
|
Success stories reported with the following imap servers (softwares
|
||||||
names are in alphabetic order) :
|
names are in alphabetic order) :
|
||||||
|
@ -200,24 +202,24 @@ IMAP SERVERS
|
||||||
2.2.1, 2.2.2-BETA, 2.2.10, 2.2.12, 2.3-alpha (OSI Approved)
|
2.2.1, 2.2.2-BETA, 2.2.10, 2.2.12, 2.3-alpha (OSI Approved)
|
||||||
(http://asg.web.cmu.edu/cyrus/)
|
(http://asg.web.cmu.edu/cyrus/)
|
||||||
- David Tobit V8 (proprietary Message system).
|
- David Tobit V8 (proprietary Message system).
|
||||||
- DBMail 1.2.1, 2.0.4, 2.0.9 (GPL) (http://www.dbmail.org/).
|
- DBMail 1.2.1, 2.0.4, 2.0.9, 2.2rc1 (GPL) (http://www.dbmail.org/).
|
||||||
2.0.7 seems buggy.
|
2.0.7 seems buggy.
|
||||||
- Dovecot 0.99.10.4 0.99.14 0.99.14-8.fc4 1.0-0.beta2.7 (LGPL)
|
- Dovecot 0.99.10.4, 0.99.14, 0.99.14-8.fc4, 1.0-0.beta2.7 (LGPL)
|
||||||
(http://www.dovecot.org/)
|
(http://www.dovecot.org/)
|
||||||
- Domino (Notes) 6.5, 5.0.6, 5.0.7
|
- Domino (Notes) 6.5, 5.0.6, 5.0.7, 7.0.2, 6.0.2CF1
|
||||||
- Eudora WorldMail v2
|
- Eudora WorldMail v2
|
||||||
- Groupwise IMAP (Novell) 6.x and 7.0. Buggy so see the FAQ.
|
- Groupwise IMAP (Novell) 6.x and 7.0. Buggy so see the FAQ.
|
||||||
- iPlanet Messaging server 4.15, 5.1, 5.2
|
- iPlanet Messaging server 4.15, 5.1, 5.2
|
||||||
- IMail 7.15 (Ipswitch/Win2003), 8.12
|
- IMail 7.15 (Ipswitch/Win2003), 8.12
|
||||||
- MDaemon 7.0.1, 8.1
|
- MDaemon 7.0.1, 8.1
|
||||||
- MS Exchange Server 5.5
|
- Microsoft Exchange Server 5.5
|
||||||
- Netscape Mail Server 3.6 (Wintel !)
|
- Netscape Mail Server 3.6 (Wintel !)
|
||||||
- Netscape Messaging Server 4.15 Patch 7
|
- Netscape Messaging Server 4.15 Patch 7
|
||||||
- OpenWave
|
- OpenWave
|
||||||
- Qualcomm Worldmail (NT)
|
- Qualcomm Worldmail (NT)
|
||||||
- Rockliffe Mailsite 5.3.11
|
- Rockliffe Mailsite 5.3.11
|
||||||
- Samsung Contact IMAP server 8.5.0
|
- Samsung Contact IMAP server 8.5.0
|
||||||
- Scalix v10.1
|
- Scalix v10.1, 10.0.1.3
|
||||||
- SunONE Messaging server 5.2, 6.0 (SUN JES - Java Enterprise System)
|
- SunONE Messaging server 5.2, 6.0 (SUN JES - Java Enterprise System)
|
||||||
- Surgemail 3.6f5-5
|
- Surgemail 3.6f5-5
|
||||||
- UW-imap servers (imap-2000b) rijkkramer IMAP4rev1 2000.287
|
- UW-imap servers (imap-2000b) rijkkramer IMAP4rev1 2000.287
|
||||||
|
@ -225,7 +227,7 @@ IMAP SERVERS
|
||||||
(http://www.washington.edu/imap/)
|
(http://www.washington.edu/imap/)
|
||||||
- UW - QMail v2.1
|
- UW - QMail v2.1
|
||||||
- Imap part of TCP/IP suite of VMS 7.3.2
|
- Imap part of TCP/IP suite of VMS 7.3.2
|
||||||
- Zimbra-IMAP 3.0.1 GA 160, 3.1.0 Build 279.
|
- Zimbra-IMAP 3.0.1 GA 160, 3.1.0 Build 279, 5.5.
|
||||||
|
|
||||||
Please report to the author any success or bad story with imapsync and
|
Please report to the author any success or bad story with imapsync and
|
||||||
don't forget to mention the IMAP server software names and version on
|
don't forget to mention the IMAP server software names and version on
|
||||||
|
@ -293,5 +295,5 @@ AUTHOR
|
||||||
teaching free open and gratis softwares. Don't hesitate to pay him for
|
teaching free open and gratis softwares. Don't hesitate to pay him for
|
||||||
that services.
|
that services.
|
||||||
|
|
||||||
$Id: imapsync,v 1.190 2006/11/11 00:13:15 gilles Exp gilles $
|
$Id: imapsync,v 1.194 2006/12/08 04:04:34 gilles Exp $
|
||||||
|
|
||||||
|
|
9
TODO
9
TODO
|
@ -1,6 +1,10 @@
|
||||||
TODO file for imapsync
|
TODO file for imapsync
|
||||||
----------------------
|
----------------------
|
||||||
|
|
||||||
|
Try a 50Mo message transfer (slow ?)
|
||||||
|
|
||||||
|
Add a best practice migration tips document,
|
||||||
|
good options with such imap server.
|
||||||
|
|
||||||
Add "output to reflect everything that imapsync was doing".
|
Add "output to reflect everything that imapsync was doing".
|
||||||
Not everything but flag synchronization will be nice"
|
Not everything but flag synchronization will be nice"
|
||||||
|
@ -18,8 +22,6 @@ problem is encountered.
|
||||||
Post on newsgroup comp.mail.imap when a new release comes.
|
Post on newsgroup comp.mail.imap when a new release comes.
|
||||||
http://groups.google.fr/group/comp.mail.imap
|
http://groups.google.fr/group/comp.mail.imap
|
||||||
|
|
||||||
Add my amazon wishlist link.
|
|
||||||
|
|
||||||
Read the IMAP RFC http://www.faqs.org/rfcs/rfc3501.html
|
Read the IMAP RFC http://www.faqs.org/rfcs/rfc3501.html
|
||||||
|
|
||||||
Add debian packaging in the Makefile.
|
Add debian packaging in the Makefile.
|
||||||
|
@ -39,6 +41,8 @@ http://asg.web.cmu.edu/cyrus/download/imapd/altnamespace.html
|
||||||
|
|
||||||
Explain expunge behavior.
|
Explain expunge behavior.
|
||||||
|
|
||||||
|
DONE. Add my amazon wishlist link.
|
||||||
|
|
||||||
DONE. Remove file rfc2342.txt "IMAP4 Namespace"
|
DONE. Remove file rfc2342.txt "IMAP4 Namespace"
|
||||||
|
|
||||||
DONE. Add an --exactsync option to remove target messages
|
DONE. Add an --exactsync option to remove target messages
|
||||||
|
@ -69,6 +73,7 @@ to talk about imapsync
|
||||||
DONE. Add a --recurse option when --folder option is used.
|
DONE. Add a --recurse option when --folder option is used.
|
||||||
No I won't since this feature can be done by doing a
|
No I won't since this feature can be done by doing a
|
||||||
--include '^INBOX.MyFolder'
|
--include '^INBOX.MyFolder'
|
||||||
|
Yes done with --folderrec
|
||||||
|
|
||||||
Done. Look at comp.mail.imap http://groups.google.fr/groups?q=imapsync
|
Done. Look at comp.mail.imap http://groups.google.fr/groups?q=imapsync
|
||||||
In fact I set up an google alert on imapsync so I read
|
In fact I set up an google alert on imapsync so I read
|
||||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
||||||
1.190
|
1.194
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
Project: imapsync
|
Project: imapsync
|
||||||
Version: 1.188
|
Version: 1.190
|
||||||
Release-Focus: Code cleanup
|
Release-Focus: Minor bugfixes
|
||||||
Hide: Y
|
Hide: Y
|
||||||
Home-Page-URL: http://www.linux-france.org/prj/imapsync/
|
Home-Page-URL: http://www.linux-france.org/prj/imapsync/
|
||||||
Gzipped-Tar-URL: http://www.linux-france.org/prj/imapsync/dist/
|
Gzipped-Tar-URL: http://www.linux-france.org/prj/imapsync/dist/
|
||||||
|
|
||||||
Updated documentation and tests
|
Bug fix: be case insensitive with header keywords.
|
||||||
|
|
||||||
|
|
51
imapsync
51
imapsync
|
@ -7,7 +7,7 @@ tool. Synchronise mailboxes between two imap servers. Good
|
||||||
at IMAP migration. More than 25 different IMAP server softwares
|
at IMAP migration. More than 25 different IMAP server softwares
|
||||||
supported with success.
|
supported with success.
|
||||||
|
|
||||||
$Revision: 1.190 $
|
$Revision: 1.194 $
|
||||||
|
|
||||||
=head1 INSTALL
|
=head1 INSTALL
|
||||||
|
|
||||||
|
@ -43,6 +43,7 @@ $Revision: 1.190 $
|
||||||
[--authmech1 <string>] [--authmech2 <string>]
|
[--authmech1 <string>] [--authmech2 <string>]
|
||||||
[--noauthmd5]
|
[--noauthmd5]
|
||||||
[--folder <string> --folder <string> ...]
|
[--folder <string> --folder <string> ...]
|
||||||
|
[--folderrec <string> --folderrec <string> ...]
|
||||||
[--include <regex>] [--exclude <regex>]
|
[--include <regex>] [--exclude <regex>]
|
||||||
[--prefix2 <string>] [--prefix1 <string>]
|
[--prefix2 <string>] [--prefix1 <string>]
|
||||||
[--regextrans2 <regex> --regextrans2 <regex> ...]
|
[--regextrans2 <regex> --regextrans2 <regex> ...]
|
||||||
|
@ -216,6 +217,7 @@ Failure stories reported with the following imap servers :
|
||||||
- DBMail 2.0.7 (GPL). But DBMail 1.2.1 works.
|
- DBMail 2.0.7 (GPL). But DBMail 1.2.1 works.
|
||||||
Patient and confident testers are welcome.
|
Patient and confident testers are welcome.
|
||||||
- dkimap4 2.39
|
- dkimap4 2.39
|
||||||
|
- Imail 7.04 (maybe).
|
||||||
|
|
||||||
Success stories reported with the following imap servers
|
Success stories reported with the following imap servers
|
||||||
(softwares names are in alphabetic order) :
|
(softwares names are in alphabetic order) :
|
||||||
|
@ -229,24 +231,24 @@ Success stories reported with the following imap servers
|
||||||
2.2.1, 2.2.2-BETA, 2.2.10, 2.2.12, 2.3-alpha (OSI Approved)
|
2.2.1, 2.2.2-BETA, 2.2.10, 2.2.12, 2.3-alpha (OSI Approved)
|
||||||
(http://asg.web.cmu.edu/cyrus/)
|
(http://asg.web.cmu.edu/cyrus/)
|
||||||
- David Tobit V8 (proprietary Message system).
|
- David Tobit V8 (proprietary Message system).
|
||||||
- DBMail 1.2.1, 2.0.4, 2.0.9 (GPL) (http://www.dbmail.org/).
|
- DBMail 1.2.1, 2.0.4, 2.0.9, 2.2rc1 (GPL) (http://www.dbmail.org/).
|
||||||
2.0.7 seems buggy.
|
2.0.7 seems buggy.
|
||||||
- Dovecot 0.99.10.4 0.99.14 0.99.14-8.fc4 1.0-0.beta2.7 (LGPL)
|
- Dovecot 0.99.10.4, 0.99.14, 0.99.14-8.fc4, 1.0-0.beta2.7 (LGPL)
|
||||||
(http://www.dovecot.org/)
|
(http://www.dovecot.org/)
|
||||||
- Domino (Notes) 6.5, 5.0.6, 5.0.7
|
- Domino (Notes) 6.5, 5.0.6, 5.0.7, 7.0.2, 6.0.2CF1
|
||||||
- Eudora WorldMail v2
|
- Eudora WorldMail v2
|
||||||
- Groupwise IMAP (Novell) 6.x and 7.0. Buggy so see the FAQ.
|
- Groupwise IMAP (Novell) 6.x and 7.0. Buggy so see the FAQ.
|
||||||
- iPlanet Messaging server 4.15, 5.1, 5.2
|
- iPlanet Messaging server 4.15, 5.1, 5.2
|
||||||
- IMail 7.15 (Ipswitch/Win2003), 8.12
|
- IMail 7.15 (Ipswitch/Win2003), 8.12
|
||||||
- MDaemon 7.0.1, 8.1
|
- MDaemon 7.0.1, 8.1
|
||||||
- MS Exchange Server 5.5
|
- Microsoft Exchange Server 5.5
|
||||||
- Netscape Mail Server 3.6 (Wintel !)
|
- Netscape Mail Server 3.6 (Wintel !)
|
||||||
- Netscape Messaging Server 4.15 Patch 7
|
- Netscape Messaging Server 4.15 Patch 7
|
||||||
- OpenWave
|
- OpenWave
|
||||||
- Qualcomm Worldmail (NT)
|
- Qualcomm Worldmail (NT)
|
||||||
- Rockliffe Mailsite 5.3.11
|
- Rockliffe Mailsite 5.3.11
|
||||||
- Samsung Contact IMAP server 8.5.0
|
- Samsung Contact IMAP server 8.5.0
|
||||||
- Scalix v10.1
|
- Scalix v10.1, 10.0.1.3
|
||||||
- SunONE Messaging server 5.2, 6.0 (SUN JES - Java Enterprise System)
|
- SunONE Messaging server 5.2, 6.0 (SUN JES - Java Enterprise System)
|
||||||
- Surgemail 3.6f5-5
|
- Surgemail 3.6f5-5
|
||||||
- UW-imap servers (imap-2000b) rijkkramer IMAP4rev1 2000.287
|
- UW-imap servers (imap-2000b) rijkkramer IMAP4rev1 2000.287
|
||||||
|
@ -254,7 +256,7 @@ Success stories reported with the following imap servers
|
||||||
(http://www.washington.edu/imap/)
|
(http://www.washington.edu/imap/)
|
||||||
- UW - QMail v2.1
|
- UW - QMail v2.1
|
||||||
- Imap part of TCP/IP suite of VMS 7.3.2
|
- Imap part of TCP/IP suite of VMS 7.3.2
|
||||||
- Zimbra-IMAP 3.0.1 GA 160, 3.1.0 Build 279.
|
- Zimbra-IMAP 3.0.1 GA 160, 3.1.0 Build 279, 5.5.
|
||||||
|
|
||||||
Please report to the author any success or bad story with
|
Please report to the author any success or bad story with
|
||||||
imapsync and don't forget to mention the IMAP server
|
imapsync and don't forget to mention the IMAP server
|
||||||
|
@ -343,7 +345,7 @@ Gilles LAMIRAL earn his living writing, installing,
|
||||||
configuring and teaching free open and gratis
|
configuring and teaching free open and gratis
|
||||||
softwares. Don't hesitate to pay him for that services.
|
softwares. Don't hesitate to pay him for that services.
|
||||||
|
|
||||||
$Id: imapsync,v 1.190 2006/11/11 00:13:15 gilles Exp gilles $
|
$Id: imapsync,v 1.194 2006/12/08 04:04:34 gilles Exp $
|
||||||
|
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
|
@ -367,7 +369,7 @@ my(
|
||||||
$rcs, $debug, $debugimap, $error,
|
$rcs, $debug, $debugimap, $error,
|
||||||
$host1, $host2, $port1, $port2,
|
$host1, $host2, $port1, $port2,
|
||||||
$user1, $user2, $password1, $password2, $passfile1, $passfile2,
|
$user1, $user2, $password1, $password2, $passfile1, $passfile2,
|
||||||
@folder, @include, @exclude,
|
@folder, @include, @exclude, @folderrec,
|
||||||
$prefix1, $prefix2,
|
$prefix1, $prefix2,
|
||||||
@regextrans2, @regexmess, @regexflag,
|
@regextrans2, @regexmess, @regexflag,
|
||||||
$sep1, $sep2,
|
$sep1, $sep2,
|
||||||
|
@ -400,7 +402,7 @@ my(
|
||||||
use vars qw ($opt_G); # missing code for this will be option.
|
use vars qw ($opt_G); # missing code for this will be option.
|
||||||
|
|
||||||
|
|
||||||
$rcs = ' $Id: imapsync,v 1.190 2006/11/11 00:13:15 gilles Exp gilles $ ';
|
$rcs = ' $Id: imapsync,v 1.194 2006/12/08 04:04:34 gilles Exp $ ';
|
||||||
$rcs =~ m/,v (\d+\.\d+)/;
|
$rcs =~ m/,v (\d+\.\d+)/;
|
||||||
$VERSION = ($1) ? $1 : "UNKNOWN";
|
$VERSION = ($1) ? $1 : "UNKNOWN";
|
||||||
|
|
||||||
|
@ -437,8 +439,8 @@ $error=0;
|
||||||
|
|
||||||
my $banner = join("",
|
my $banner = join("",
|
||||||
'$RCSfile: imapsync,v $ ',
|
'$RCSfile: imapsync,v $ ',
|
||||||
'$Revision: 1.190 $ ',
|
'$Revision: 1.194 $ ',
|
||||||
'$Date: 2006/11/11 00:13:15 $ ',
|
'$Date: 2006/12/08 04:04:34 $ ',
|
||||||
"\n",
|
"\n",
|
||||||
"Mail::IMAPClient version used here is ",
|
"Mail::IMAPClient version used here is ",
|
||||||
$VERSION_IMAPClient,"\n"
|
$VERSION_IMAPClient,"\n"
|
||||||
|
@ -504,8 +506,8 @@ $user1 || missing_option("--user1");
|
||||||
$user2 || missing_option("--user2");
|
$user2 || missing_option("--user2");
|
||||||
|
|
||||||
if(defined($authmd5) and not($authmd5)) {
|
if(defined($authmd5) and not($authmd5)) {
|
||||||
$authmech1 ||= 'PLAIN';
|
$authmech1 ||= 'LOGIN';
|
||||||
$authmech2 ||= 'PLAIN';
|
$authmech2 ||= 'LOGIN';
|
||||||
}else{
|
}else{
|
||||||
$authmech1 ||= $authuser1 ? 'PLAIN' : 'CRAM-MD5';
|
$authmech1 ||= $authuser1 ? 'PLAIN' : 'CRAM-MD5';
|
||||||
$authmech2 ||= $authuser2 ? 'PLAIN' : 'CRAM-MD5';
|
$authmech2 ||= $authuser2 ? 'PLAIN' : 'CRAM-MD5';
|
||||||
|
@ -674,16 +676,23 @@ my (@f_folders, @t_folders, %fs_folders);
|
||||||
map { $fs_folders{$_}=1 } $from->subscribed();
|
map { $fs_folders{$_}=1 } $from->subscribed();
|
||||||
|
|
||||||
|
|
||||||
if (scalar(@folder)) {
|
if (scalar(@folder) or $subscribed or scalar(@folderrec)) {
|
||||||
# folders given by option --folder
|
# folders given by option --folder
|
||||||
@f_folders = @folder;
|
push(@f_folders, @folder) if scalar(@folder);
|
||||||
}elsif ($subscribed) {
|
|
||||||
# option --subscribed
|
# option --subscribed
|
||||||
@f_folders = sort keys (%fs_folders);
|
push(@f_folders, sort keys (%fs_folders)) if ($subscribed);
|
||||||
|
|
||||||
|
if (scalar(@folderrec)) {
|
||||||
|
foreach my $folderrec (@folderrec) {
|
||||||
|
push(@f_folders, $from->folders($folderrec));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@f_folders = sort @f_folders;
|
||||||
}else {
|
}else {
|
||||||
# no option, all folders
|
# no folder/subscribed/folderrec options => all folders
|
||||||
@f_folders = sort $from->folders();
|
@f_folders = sort $from->folders();
|
||||||
# consider (optional) includes and excludes
|
# consider (optional) includes and excludes
|
||||||
|
# WARNING the following two loops are bad with more than one pass.
|
||||||
foreach my $include (@include) {
|
foreach my $include (@include) {
|
||||||
@f_folders = grep /$include/,@f_folders;
|
@f_folders = grep /$include/,@f_folders;
|
||||||
print "Only including folders matching pattern '$include'\n";
|
print "Only including folders matching pattern '$include'\n";
|
||||||
|
@ -1261,6 +1270,7 @@ sub get_options
|
||||||
"sep1=s" => \$sep1,
|
"sep1=s" => \$sep1,
|
||||||
"sep2=s" => \$sep2,
|
"sep2=s" => \$sep2,
|
||||||
"folder=s" => \@folder,
|
"folder=s" => \@folder,
|
||||||
|
"folderrec=s" => \@folderrec,
|
||||||
"include=s" => \@include,
|
"include=s" => \@include,
|
||||||
"exclude=s" => \@exclude,
|
"exclude=s" => \@exclude,
|
||||||
"prefix1=s" => \$prefix1,
|
"prefix1=s" => \$prefix1,
|
||||||
|
@ -1412,8 +1422,9 @@ Several options are mandatory.
|
||||||
--ssl1 : use an SSL connection on host1.
|
--ssl1 : use an SSL connection on host1.
|
||||||
--ssl2 : use an SSL connection on host2.
|
--ssl2 : use an SSL connection on host2.
|
||||||
--folder <string> : sync only this folder.
|
--folder <string> : sync only this folder.
|
||||||
--folder <string> : and this one.
|
|
||||||
--folder <string> : and this one, etc.
|
--folder <string> : and this one, etc.
|
||||||
|
--folderrec <string> : sync only this folder recursively.
|
||||||
|
--folderrec <string> : and this one, etc.
|
||||||
--include <regex> : only sync folders matching this regular expression
|
--include <regex> : only sync folders matching this regular expression
|
||||||
(only effective if neither --folder nor --subscribed
|
(only effective if neither --folder nor --subscribed
|
||||||
is specified).
|
is specified).
|
||||||
|
|
12
patches/imapsync-base64.patch
Normal file
12
patches/imapsync-base64.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
diff -u -r imapsync-1.182/imapsync imapsync-1.182-base64-fix/imapsync
|
||||||
|
--- imapsync-1.182/imapsync 2006-08-01 16:07:42.000000000 -0700
|
||||||
|
+++ imapsync-1.182-base64-fix/imapsync 2006-09-27 16:09:59.000000000 -0700
|
||||||
|
@@ -635,7 +635,7 @@
|
||||||
|
|
||||||
|
my $string = sprintf("%s\x00%s\x00%s", $imap->User,
|
||||||
|
$imap->Authuser, $imap->Password);
|
||||||
|
- return encode_base64("$string");
|
||||||
|
+ return encode_base64("$string", "");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
19
tests.sh
19
tests.sh
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# $Id: tests.sh,v 1.55 2006/10/30 01:19:46 gilles Exp gilles $
|
# $Id: tests.sh,v 1.56 2006/12/08 04:05:01 gilles Exp $
|
||||||
|
|
||||||
#### Shell pragmas
|
#### Shell pragmas
|
||||||
|
|
||||||
|
@ -117,6 +117,20 @@ ll_folder() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ll_folderrec() {
|
||||||
|
if test X`hostname` = X"plume"; then
|
||||||
|
echo3 Here is plume
|
||||||
|
./imapsync \
|
||||||
|
--host1 localhost --user1 tata@est.belle \
|
||||||
|
--passfile1 /var/tmp/secret.tata \
|
||||||
|
--host2 localhost --user2 titi@est.belle \
|
||||||
|
--passfile2 /var/tmp/secret.titi \
|
||||||
|
--folderrec INBOX.yop
|
||||||
|
else
|
||||||
|
:
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ll_buffersize() {
|
ll_buffersize() {
|
||||||
|
@ -819,7 +833,8 @@ test $# -eq 0 && run_tests \
|
||||||
ll_authmech_LOGIN \
|
ll_authmech_LOGIN \
|
||||||
ll_authmech_CRAMMD5 \
|
ll_authmech_CRAMMD5 \
|
||||||
ll_authuser \
|
ll_authuser \
|
||||||
ll_delete2
|
ll_delete2 \
|
||||||
|
ll_folderrec
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue