Gnus development mailing list
 help / color / mirror / Atom feed
From: Kai.Grossjohann@CS.Uni-Dortmund.DE (Kai Großjohann)
Subject: Re: ISO date in attribution line
Date: Sun, 09 Jun 2002 21:40:12 +0200	[thread overview]
Message-ID: <vafk7p8nsv7.fsf@INBOX.auto.gnus.tok.lucy.cs.uni-dortmund.de> (raw)
In-Reply-To: <E17H7Wr-0005sR-00@eris.void.at> (Andreas Fuchs's message of "Sun, 09 Jun 2002 20:35:05 +0200")

Andreas Fuchs <asf@void.at> writes:

> ,----
> | (defun sc-jk-normalize-date (date)
> |   "Extract the date (day month year) from an RFC 822 message
> | and write it as year-month-day (ISO 8601)"
> |   (let ((date-list (cdr (cdr (cdr (parse-time-string date))))))
> |     (let ((day (pop date-list)))
> |       (let ((month (pop date-list)))
> | 	(let ((year (car date-list)))
> | 	  (and 
> | 	   year month day 
> | 	   (format "%d-%02d-%02d" year month day)))))))
> `----

I get the feeling that doing format-time-string on the result of
parse-time-string would be enough.  Anyone want to try this?

(defun sc-jk-normalize-date (date)
  "..."
  (let ((date (encode-time (parse-time-string date))))
    (format-time-string "..." date)))

kai
-- 
~/.signature is: umop 3p!sdn    (Frank Nobis)



  reply	other threads:[~2002-06-09 19:40 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-24 15:59 The followup will show the bug Kai Großjohann
2002-05-24 21:45 ` Reiner Steib
2002-05-25 17:22   ` Kai Großjohann
2002-05-25 17:49     ` Oystein Viggen
2002-05-27 13:47       ` Christopher Splinter
2002-05-27 14:40         ` Kai Großjohann
2002-05-27 15:32           ` Oystein Viggen
2002-05-27 19:07             ` Paul Jarc
2002-05-28 11:06               ` Christopher Splinter
2002-05-28  6:30           ` Niklas Morberg
2002-05-28  7:30             ` he " Marco Lonsing
2002-05-28  7:38             ` The " David Kågedal
2002-05-28  7:38             ` David Kågedal
2002-05-28  9:21             ` Kai Großjohann
2002-05-29  9:33               ` Niklas Morberg
     [not found]             ` <u5tptzg90xj.fsf@leeloo.hq.vtech>
2002-05-28  8:12               ` Ronan Waide
2002-05-28 22:24               ` Alex Schroeder
2002-05-28 11:03           ` Christopher Splinter
2002-05-27 17:59     ` Jesper Harder
2002-05-28 13:01       ` Kai Großjohann
2002-05-28 13:31       ` Kai Großjohann
2002-05-28 13:31         ` Kai Großjohann
2002-05-28 16:36           ` Jesper Harder
2002-05-29  7:38             ` Kai Großjohann
2002-05-29 18:26               ` Johann Gambolputty de von ausfern schplenden schlitter...von Hautkopft of Ulm
2002-05-29 20:11                 ` Jesper Harder
2002-05-30  9:57                   ` Kai Großjohann
2002-05-30 10:01                     ` Kai Großjohann
2002-05-30  9:56                 ` Kai Großjohann
2002-05-28 17:36         ` Christopher Splinter
2002-05-25 20:28 ` Andreas Fuchs
2002-06-09 18:04   ` ISO date in attribution line (Was: Re: The followup will show the bug.) Svend Tollak Munkejord
2002-06-09 18:35     ` ISO date in attribution line Andreas Fuchs
2002-06-09 19:40       ` Kai Großjohann [this message]
2002-06-09 20:22         ` lawrence mitchell
2002-06-10  9:36           ` Kai Großjohann
2002-06-10 17:16             ` Andreas Fuchs
2002-06-11 10:51               ` Kai Großjohann
2002-06-09 20:40         ` Andreas Fuchs
2002-06-09 20:59       ` Svend Tollak Munkejord

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=vafk7p8nsv7.fsf@INBOX.auto.gnus.tok.lucy.cs.uni-dortmund.de \
    --to=kai.grossjohann@cs.uni-dortmund.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).