diff --git a/postler/postler-accounts.vala b/postler/postler-accounts.vala index 0c16ee8..1f2b120 100644 --- a/postler/postler-accounts.vala +++ b/postler/postler-accounts.vala @@ -419,6 +419,15 @@ public class Postler.Accounts : GLib.Object { if (certificate != null && !Path.is_absolute (certificate)) certificate = info.path + "/" + certificate; + string[] hidden_tmp = info.hide.split (","); + string hidden_folders = ""; + foreach (var hidden in hidden_tmp) { + if (hidden.contains (" ")) + hidden_folders += " \"!" + hidden + "\""; + else + hidden_folders += " !" + hidden; + } + if (send != null) { string msmtprc = """ defaults @@ -460,7 +469,7 @@ public class Postler.Accounts : GLib.Object { Host %s User %s Pass %s - Path %s + #Path %s UseIMAPS yes CertificateFile %s %s %s @@ -473,6 +482,7 @@ public class Postler.Accounts : GLib.Object { Master :remote: Slave :local: Patterns %% * !INBOX + Patterns %% %s Group mirror Channel local-remote:INBOX @@ -487,8 +497,10 @@ public class Postler.Accounts : GLib.Object { certificate != null ? "CertificateFile" : "", certificate != null ? certificate : "", info.path, - info.path + info.path, + hidden_folders.replace ("~-", "/") ); + stdout.printf (mbsyncrc); FileUtils.set_contents (filename, mbsyncrc, -1); FileUtils.chmod (filename, 0700); break; diff --git a/waf b/waf index 22d00ed..36a4014 100755 Binary files a/waf and b/waf differ