[Patchew-devel] [PATCH] importer: Prune messages in IMAP server after import

Fam Zheng posted 1 patch 23 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/patchew-ci tags/patchew/20180703060049.19161-1-famz@redhat.com
scripts/patchew-importer | 2 ++
1 file changed, 2 insertions(+)

[Patchew-devel] [PATCH] importer: Prune messages in IMAP server after import

Posted by Fam Zheng 23 weeks ago
Don't wait until the next offlineimap_import() to delete messages from
mail server, this saves work for next time if we quit before the next
iteration.

Signed-off-by: Fam Zheng <famz@redhat.com>
---
 scripts/patchew-importer | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/scripts/patchew-importer b/scripts/patchew-importer
index d9de74f..e372068 100755
--- a/scripts/patchew-importer
+++ b/scripts/patchew-importer
@@ -101,6 +101,8 @@ offlineimap_import()
         fi
         import "$f" || true
     done
+    # Flush message deletions
+    timeout -k 2000 1800 offlineimap -c $offlineimap_rc
 }
 
 while :; do
-- 
2.17.1

_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel

Re: [Patchew-devel] [PATCH] importer: Prune messages in IMAP server after import

Posted by Paolo Bonzini 23 weeks ago
On 03/07/2018 08:00, Fam Zheng wrote:
> Don't wait until the next offlineimap_import() to delete messages from
> mail server, this saves work for next time if we quit before the next
> iteration.
> 
> Signed-off-by: Fam Zheng <famz@redhat.com>
> ---
>  scripts/patchew-importer | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/scripts/patchew-importer b/scripts/patchew-importer
> index d9de74f..e372068 100755
> --- a/scripts/patchew-importer
> +++ b/scripts/patchew-importer
> @@ -101,6 +101,8 @@ offlineimap_import()
>          fi
>          import "$f" || true
>      done
> +    # Flush message deletions
> +    timeout -k 2000 1800 offlineimap -c $offlineimap_rc
>  }
>  
>  while :; do
> 

Looks good, though I don't know much about the importer.

Paolo

_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel