Gnus development mailing list
 help / color / mirror / Atom feed
* gnus-message-archive-group
@ 2012-07-12 15:14 Julien Cubizolles
  2012-07-12 15:34 ` gnus-message-archive-group Adam Sjøgren
  2012-07-12 16:01 ` gnus-message-archive-group Andreas Schwab
  0 siblings, 2 replies; 6+ messages in thread
From: Julien Cubizolles @ 2012-07-12 15:14 UTC (permalink / raw)
  To: ding

I'm trying to use the date-named groups for archiving my sent messages
but to separate news and mail messages. I tried the following :

((if
     (message-news-p)
     (format-time-string "sent-news.%Y-%m")
   (format-time-string "sent-mail.%Y-%m")))

but it fails with

Saving file /home/wilk/Mail/archive/sent-mail/2012-07...
basic-save-buffer-2: /home/wilk/Mail/archive/sent-mail/: no such directory

Inded there is no /home/wilk/Mail/archive/sent-mail/ directory but the
messages where saved to the *file* /home/wilk/Mail/archive/sent-mail when
I used :

((if (message-news-p) "sent-news" "sent-mail"))

What am I missing ?

Julien Cubizolles.




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gnus-message-archive-group
  2012-07-12 15:14 gnus-message-archive-group Julien Cubizolles
@ 2012-07-12 15:34 ` Adam Sjøgren
  2012-07-12 22:09   ` gnus-message-archive-group Julien Cubizolles
  2012-07-12 16:01 ` gnus-message-archive-group Andreas Schwab
  1 sibling, 1 reply; 6+ messages in thread
From: Adam Sjøgren @ 2012-07-12 15:34 UTC (permalink / raw)
  To: ding

On Thu, 12 Jul 2012 17:14:01 +0200, Julien wrote:

> I'm trying to use the date-named groups for archiving my sent messages
> but to separate news and mail messages. I tried the following :

> ((if
>      (message-news-p)
>      (format-time-string "sent-news.%Y-%m")
>    (format-time-string "sent-mail.%Y-%m")))

How did you set up your archive server?

I have this in my ~/.gnus - it may very well to horribly outdated (but
works for me with ma gnus from git):

    ;  Archive outgoing articles:
    (setq gnus-message-archive-method '(nnml "archive"
                                             (nnml-directory "~/Mail/archive")
                                             (nnml-active-file "~/Mail/archive/active")
                                             (nnml-get-new-mail nil)
                                             (nnml-inhibit-expiry t)))

    (setq gnus-message-archive-group
          '((if (message-news-p)
                (concat "news-" (format-time-string "%Y"))
              (concat "mail-" (format-time-string "%Y")))))

I keep all my email, archives included, in nnml format, and only have
groups for email/news per year - so this may be way off from what you
want.


  Best regards,

    Adam

-- 
 "Det er jo bare punk, forklædt som Bubbers badekar!"         Adam Sjøgren
                                                         asjo@koldfront.dk




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gnus-message-archive-group
  2012-07-12 15:14 gnus-message-archive-group Julien Cubizolles
  2012-07-12 15:34 ` gnus-message-archive-group Adam Sjøgren
@ 2012-07-12 16:01 ` Andreas Schwab
  2012-07-12 19:18   ` gnus-message-archive-group Julien Cubizolles
  1 sibling, 1 reply; 6+ messages in thread
From: Andreas Schwab @ 2012-07-12 16:01 UTC (permalink / raw)
  To: Julien Cubizolles; +Cc: ding

Julien Cubizolles <j.cubizolles@free.fr> writes:

> I'm trying to use the date-named groups for archiving my sent messages
> but to separate news and mail messages. I tried the following :
>
> ((if
>      (message-news-p)
>      (format-time-string "sent-news.%Y-%m")
>    (format-time-string "sent-mail.%Y-%m")))

Are you sure you didn't use "sent-mail/%Y-%m"?

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gnus-message-archive-group
  2012-07-12 16:01 ` gnus-message-archive-group Andreas Schwab
@ 2012-07-12 19:18   ` Julien Cubizolles
  0 siblings, 0 replies; 6+ messages in thread
From: Julien Cubizolles @ 2012-07-12 19:18 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: ding

Andreas Schwab <schwab@linux-m68k.org> writes:

> Julien Cubizolles <j.cubizolles@free.fr> writes:
>
>> I'm trying to use the date-named groups for archiving my sent messages
>> but to separate news and mail messages. I tried the following :
>>
>> ((if
>>      (message-news-p)
>>      (format-time-string "sent-news.%Y-%m")
>>    (format-time-string "sent-mail.%Y-%m")))
>
> Are you sure you didn't use "sent-mail/%Y-%m"?

Yes I am, I copy-pasted the relevant line from my .gnus.el

Julien.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gnus-message-archive-group
  2012-07-12 15:34 ` gnus-message-archive-group Adam Sjøgren
@ 2012-07-12 22:09   ` Julien Cubizolles
  2012-07-12 22:34     ` gnus-message-archive-group Adam Sjøgren
  0 siblings, 1 reply; 6+ messages in thread
From: Julien Cubizolles @ 2012-07-12 22:09 UTC (permalink / raw)
  To: ding

asjo@koldfront.dk (Adam Sjøgren) writes:

> On Thu, 12 Jul 2012 17:14:01 +0200, Julien wrote:
>
>> I'm trying to use the date-named groups for archiving my sent messages
>> but to separate news and mail messages. I tried the following :
>
>> ((if
>>      (message-news-p)
>>      (format-time-string "sent-news.%Y-%m")
>>    (format-time-string "sent-mail.%Y-%m")))
>
> How did you set up your archive server?

I didn't change the default settings


>     (setq gnus-message-archive-group
>           '((if (message-news-p)
>                 (concat "news-" (format-time-string "%Y"))
>               (concat "mail-" (format-time-string "%Y")))))

I tried a slight modification of my setup, replacing a "." by a "-" : 

,----
| (setq gnus-message-archive-group 
|       '((if (message-news-p)
| 	    (format-time-string "sent-news-%Y-%m")
|           (format-time-string "sent-mail-%Y-%m")
| 	  )))
`----

and I don't have any problem anymore... There's definitely something
strange going on here, but I can live with it. Maybe someone more
knowledgeable with lisp than I am can spot the problem.

Julien.




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gnus-message-archive-group
  2012-07-12 22:09   ` gnus-message-archive-group Julien Cubizolles
@ 2012-07-12 22:34     ` Adam Sjøgren
  0 siblings, 0 replies; 6+ messages in thread
From: Adam Sjøgren @ 2012-07-12 22:34 UTC (permalink / raw)
  To: ding

On Fri, 13 Jul 2012 00:09:54 +0200, Julien wrote:

> I tried a slight modification of my setup, replacing a "." by a "-" : 

Good hunch!

I am guessing that a.newsgroup.like.this translates to
a/newsgroup/like/this in the directory structure, and that is why '-'
works better than '.' (just a guess, though).


  Best regards,

    Adam

-- 
 "HALLELUJAH!                                                 Adam Sjøgren
  Så att säga."                                          asjo@koldfront.dk




^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-07-12 22:34 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-12 15:14 gnus-message-archive-group Julien Cubizolles
2012-07-12 15:34 ` gnus-message-archive-group Adam Sjøgren
2012-07-12 22:09   ` gnus-message-archive-group Julien Cubizolles
2012-07-12 22:34     ` gnus-message-archive-group Adam Sjøgren
2012-07-12 16:01 ` gnus-message-archive-group Andreas Schwab
2012-07-12 19:18   ` gnus-message-archive-group Julien Cubizolles

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).