From fa766b61bcf5dcc1f241c96521b56304a0e3ba11 Mon Sep 17 00:00:00 2001 From: John Goerzen Date: Tue, 20 May 2008 01:13:36 -0500 Subject: [PATCH] Initial stab at showing list of folders that aren't being synced This isn't working right yet because two accounts could sync into one destination --- offlineimap/repository/Base.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/offlineimap/repository/Base.py b/offlineimap/repository/Base.py index ed07b57..ec56d61 100644 --- a/offlineimap/repository/Base.py +++ b/offlineimap/repository/Base.py @@ -17,6 +17,7 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA from offlineimap import CustomConfig +from offlineimap.ui import UIBase import os.path def LoadRepository(name, account, reqtype): @@ -164,6 +165,17 @@ class BaseRepository(CustomConfig.ConfigHelperMixin): #for key in desthash.keys(): # if not key in srchash: # dest.deletefolder(key) + + + ##### Find any folders that aren't being synced + ignoredfolders = [] + for key in desthash.keys(): + if not key in srchash: + ignoredfolders.append(key) + + ignoredfolders.sort() + if ignoredfolders != []: + UIBase.getglobalui().warn("Found local folders that are not being synced: %s" % (", ".join(ignoredfolders))) ##### Keepalive -- 2.39.2