1 |
;;; nnimap.el --- imap backend for Gnus |
;;; nnimap.el --- imap backend for Gnus |
2 |
;; Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. |
;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. |
3 |
|
|
4 |
;; Author: Simon Josefsson <jas@pdc.kth.se> |
;; Author: Simon Josefsson <jas@pdc.kth.se> |
5 |
;; Jim Radford <radford@robby.caltech.edu> |
;; Jim Radford <radford@robby.caltech.edu> |
1088 |
|
|
1089 |
(defun nnimap-date-days-ago (daysago) |
(defun nnimap-date-days-ago (daysago) |
1090 |
"Return date, in format \"3-Aug-1998\", for DAYSAGO days ago." |
"Return date, in format \"3-Aug-1998\", for DAYSAGO days ago." |
1091 |
(let ((date (format-time-string "%d-%b-%Y" |
(let* ((time (nnimap-time-substract (current-time) (days-to-time daysago))) |
1092 |
(nnimap-time-substract |
(date (format-time-string |
1093 |
(current-time) |
(format "%%d-%s-%%Y" |
1094 |
(days-to-time daysago))))) |
(capitalize (car (rassoc (nth 4 (decode-time time)) |
1095 |
|
parse-time-months)))) |
1096 |
|
time))) |
1097 |
(if (eq ?0 (string-to-char date)) |
(if (eq ?0 (string-to-char date)) |
1098 |
(substring date 1) |
(substring date 1) |
1099 |
date))) |
date))) |