Gnus development mailing list
 help / color / mirror / Atom feed
From: Patric Mueller <bhaak@gmx.net>
Subject: [patch] bug in timestamp example in gnus-3
Date: Thu, 17 Jan 2002 06:16:02 +0100	[thread overview]
Message-ID: <lzy9ixftgt.fsf@bhaak.xodox.com> (raw)


Hi

The example for the user defined date format doesn't work. 
There's a typo (%ud not %Ud) and then it doesn't work as expected.

If the group has never been assigned a timestamp instead of nothing,
time will be nil and format-time-string then takes the current time. 

This little patch should fix that. 

Bye
Patric


--- gnus-3.orig Mon Jan 14 18:18:13 2002
+++ gnus-3      Thu Jan 17 05:42:53 2002
@@ -635,10 +635,10 @@
 trick:
 
      (setq gnus-group-line-format
-           "%M\%S\%p\%P\%5y: %(%-40,40g%) %Ud\n")
+           "%M\%S\%p\%P\%5y: %(%-40,40g%) %ud\n")
      (defun gnus-user-format-function-d (headers)
        (let ((time (gnus-group-timestamp gnus-tmp-group)))
-         (format-time-string "%b %d  %H:%M" time)))
+         (if time (format-time-string "%b %d  %H:%M" time) (make-string 0 ?x))))
 
 
 File: gnus,  Node: File Commands,  Next: Sieve Commands,  Prev: Group Timestamp,  Up: Misc Group Stuff



             reply	other threads:[~2002-01-17  5:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-17  5:16 Patric Mueller [this message]
2002-01-19 23:52 ` Lars Magne Ingebrigtsen

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=lzy9ixftgt.fsf@bhaak.xodox.com \
    --to=bhaak@gmx.net \
    /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).