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

Re: [sup-talk] deleting files from source



Excerpts from Chris Parsons's message of Wed Oct 20 02:26:13 -0300 2010:
> On Tue, 19 Oct 2010 02:52:54 +0100, Daniel Hernández <daniel@degu.cl>  
> wrote:
> 
> > I started using sup recently. Now I have only one source that is a
> > inbox maildir folder. I want to delete some emails from the source
> > forever, but when I delete or kill emails they are not really deleted
> > from the maildir folder. How can I clean the maildir folder, removing
> > deleted or killed emails?
> 
> The design intent of sup is to specifically remove the need to worry about  
> deleting e-mails. But if you really need to do that then one way might be  
> to do the following (assuming your machine has the right tools installed).  
> Doing stuff like this could lose your messages. Info supplied for  
> education purposes only. Proceed at your own risk!

The reason because I need to delete some emails is that I read emails
in several computers. In each computer I have sup installed and I
synchronize the maildir with other maildirs using a primary imap
server. Thus I like to delete some unimportant emails to reduce the
network traffic.

I started with this practice using mutt and the wanderlust email
client, but I prefer the sup email client. I like the tagging system
of sup and its capacity to manage threads. But now I have another
problem, because tags are not stored in the maildir and I don't know
how to synchronize tags in several computers.
 
> # change to top of the Maildir
>    cd ~/Mail
> # get message id of all files with tag 'deleted' and put in temp file
>    FL=/tmp/del-filelist
>    rm -f $FL
>    for i in `sup-dump | grep deleted | cut -f 1 -d' '`; do grep -l -r $i  
> ./*  >> $FL;done
> # delete the files in the file list
>    for i in `cat $FL`; do rm $i; done
> # sync the index. New versions of sup-sync don't have the --changed  
> argument
>    sup-sync --verbose --changed
> 
> repeat for "killed" instead of "deleted"

That works fine, but I have written some modifications because my
maildir don't store emails using the message-id.

Thanks,
Daniel
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk