[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: archive NG msgs
From: |
Leo |
Subject: |
Re: archive NG msgs |
Date: |
Sun, 17 Jun 2007 10:51:05 +0100 |
User-agent: |
Gnus/5.110007 Emacs 23 (20070616) MULE/6.0 (HANACHIRUSATO) Fedora 7 (gnu/linux) |
----- Dick Hoogendijk (2007-06-17) wrote:-----
> I read lots of news and sometimes I want to save msgs for future
> reference. I can mark them with 'u' but what I really want is copy
> them to aan archive. "M c" copies alright but never remembers the name
> of the archive(s). Is there some kind of shortway to 'archive' NG msgs
> always to the same place? Be it nnimap, nnfolder or whatever..
>
> Sure I can (mail) copy them with "C-c C-f" but I'd like it even more
> automated and easy. Any tips?
I use the following in my .gnus which I seem to copy from somewhere:
(defun my-gnus-summary-archive-article ()
"Copy current article to a suitable nnml archive group.
The copied article will be marked as \"ancient\", the original
will retain its current marks."
(interactive)
(let* ((group-name
(if (string-match "nnimap" gnus-newsgroup-name)
gnus-newsgroup-name
(car (last (split-string gnus-newsgroup-name ":")))))
(archive-name (concat "nnml:archive." group-name))
(orig-mark (gnus-summary-article-mark)))
(gnus-summary-mark-article nil gnus-ancient-mark t)
(gnus-summary-copy-article 1 archive-name)
(gnus-summary-mark-article nil orig-mark t)))
Best,
--
Leo <sdl.web AT gmail.com> (GPG Key: 9283AA3F)