commit-mailutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[SCM] GNU Mailutils branch, master, updated. release-2.2-606-g8ef7c0a


From: Sergey Poznyakoff
Subject: [SCM] GNU Mailutils branch, master, updated. release-2.2-606-g8ef7c0a
Date: Thu, 07 Jun 2012 04:33:54 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Mailutils".

http://git.savannah.gnu.org/cgit/mailutils.git/commit/?id=8ef7c0ad473e5271fb349a69c819675e242235a2

The branch, master has been updated
       via  8ef7c0ad473e5271fb349a69c819675e242235a2 (commit)
      from  4c2e6902643219c600504688bb59881465cc5536 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 8ef7c0ad473e5271fb349a69c819675e242235a2
Author: Sergey Poznyakoff <address@hidden>
Date:   Thu Jun 7 07:31:30 2012 +0300

    Implement two new Scheme functions.
    
    * NEWS: Update.
    * configure.ac: Version 2.99.97
    * libmu_scm/mu_mailbox.c (mu-mailbox-sync)
    (mu-mailbox-flush): New functions.

-----------------------------------------------------------------------

Summary of changes:
 NEWS                   |   22 ++++++++++++++++++++--
 configure.ac           |    2 +-
 libmu_scm/mu_mailbox.c |   45 +++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 66 insertions(+), 3 deletions(-)

diff --git a/NEWS b/NEWS
index 1da261c..4017176 100644
--- a/NEWS
+++ b/NEWS
@@ -1,11 +1,11 @@
-GNU mailutils NEWS -- history of user-visible changes. 2012-05-31
+GNU mailutils NEWS -- history of user-visible changes. 2012-06-07
 Copyright (C) 2002-2012 Free Software Foundation, Inc.
 See the end of file for copying conditions.
 
 Please send mailutils bug reports to <address@hidden>.
 
 
-Version 2.99.96 (Git)
+Version 2.99.97 (Git)
 
 This version is a major rewrite of GNU Mailutils.  Quite a few parts
 of the basic framework were rewritten from scratch, while some others
@@ -254,6 +254,24 @@ See <http://mailutils.org/wiki/debug_level>.
 
 ** Configuration file support (libmu_cfg) rewritten.
 
+* New Scheme primitives
+
+** mu-mailbox-sync
+
+Synchronizes the changes done to the mailbox with its external
+storage.
+
+** mu-mailbox-expunge
+
+Similar to mu-mailbox-sync, but also permanently removes messages
+marked for deletion.
+
+** mu-mailbox-flush
+
+Marks all messages as seen, and synchronizes the changes with the
+mailbox external storage.  Depending on its second argument, removes
+messages marked for deletion.
+
 
 Version 2.2 - 2010-09-08
 
diff --git a/configure.ac b/configure.ac
index cb07ad4..ec3b416 100644
--- a/configure.ac
+++ b/configure.ac
@@ -16,7 +16,7 @@ dnl You should have received a copy of the GNU General Public 
License along
 dnl with GNU Mailutils.  If not, see <http://www.gnu.org/licenses/>.
 
 AC_PREREQ(2.63)
-AC_INIT([GNU Mailutils], [2.99.96], address@hidden, [mailutils])
+AC_INIT([GNU Mailutils], [2.99.97], address@hidden, [mailutils])
 AC_CONFIG_SRCDIR([libmailutils/mailbox/mailbox.c])
 AC_CONFIG_AUX_DIR([build-aux])
 AM_INIT_AUTOMAKE([gnits 1.11 dist-bzip2 dist-xz std-options silent-rules])
diff --git a/libmu_scm/mu_mailbox.c b/libmu_scm/mu_mailbox.c
index 9699b0d..5345f95 100644
--- a/libmu_scm/mu_mailbox.c
+++ b/libmu_scm/mu_mailbox.c
@@ -373,6 +373,51 @@ SCM_DEFINE_PUBLIC (scm_mu_mailbox_expunge, 
"mu-mailbox-expunge", 1, 0, 0,
 }
 #undef FUNC_NAME
 
+SCM_DEFINE_PUBLIC (scm_mu_mailbox_sync, "mu-mailbox-sync", 1, 0, 0,
+                  (SCM mbox), 
+"Synchronize changes to @var{mbox} with its storage.")
+#define FUNC_NAME s_scm_mu_mailbox_sync
+{
+  struct mu_mailbox *mum;
+  int status;
+    
+  SCM_ASSERT (mu_scm_is_mailbox (mbox), mbox, SCM_ARG1, FUNC_NAME);
+  mum = (struct mu_mailbox *) SCM_CDR (mbox);
+  status = mu_mailbox_sync (mum->mbox);
+  if (status)
+    mu_scm_error (FUNC_NAME, status,
+                 "Sync failed for mailbox ~A",
+                 scm_list_1 (mbox));
+  return SCM_BOOL_T;
+}
+#undef FUNC_NAME
+
+SCM_DEFINE_PUBLIC (scm_mu_mailbox_flush, "mu-mailbox-flush", 1, 1, 0,
+                  (SCM mbox, SCM expunge), 
+"Mark all messages in @var{mbox} as seen and synchronize all changes with "
+"its storage.  If @var{expunge} is @samp{#t}, expunge deleted messages "
+"as well.")
+#define FUNC_NAME s_scm_mu_mailbox_flush
+{
+  struct mu_mailbox *mum;
+  int status, do_expunge = 0;
+    
+  SCM_ASSERT (mu_scm_is_mailbox (mbox), mbox, SCM_ARG1, FUNC_NAME);
+  mum = (struct mu_mailbox *) SCM_CDR (mbox);
+  if (!SCM_UNBNDP (expunge))
+    {
+      SCM_ASSERT (scm_is_bool (expunge), expunge, SCM_ARG2, FUNC_NAME);
+      do_expunge = expunge == SCM_BOOL_T;
+    }
+  status = mu_mailbox_flush (mum->mbox, do_expunge);
+  if (status)
+    mu_scm_error (FUNC_NAME, status,
+                 "Flush failed for mailbox ~A",
+                 scm_list_1 (mbox));
+  return SCM_BOOL_T;
+}
+#undef FUNC_NAME
+
 SCM_DEFINE_PUBLIC (scm_mu_mailbox_append_message, "mu-mailbox-append-message", 
2, 0, 0,
                   (SCM mbox, SCM mesg),
                   "Appends message @var{mesg} to the mailbox @var{mbox}.")


hooks/post-receive
-- 
GNU Mailutils



reply via email to

[Prev in Thread] Current Thread [Next in Thread]