diff options
author | Julien Danjou <julien@danjou.info> | 2010-10-06 12:21:34 +0200 |
---|---|---|
committer | Julien Danjou <julien@danjou.info> | 2010-10-06 12:21:34 +0200 |
commit | f6c901c6f4de07059384710974c118a80643e72d (patch) | |
tree | 0bb4fea3ebef1d512d1bb69cdff5b05af475383b /offlineimap.el | |
parent | f88e8b93080f40de1c4683ff550239ecd632505c (diff) |
Add support for timestamp
Diffstat (limited to 'offlineimap.el')
-rw-r--r-- | offlineimap.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/offlineimap.el b/offlineimap.el index 04efe53..4f102b1 100644 --- a/offlineimap.el +++ b/offlineimap.el @@ -64,6 +64,11 @@ action as a text in color instead of a single symbol.") "Symbol used to display OfflineIMAP status in mode-line. This is used when `offlineimap-mode-line-style' is set to 'symbol.") +(defcustom offlineimap-timestamp nil + "Timestamp to add at the beginning of each OffsyncIMAP line." + :type 'string + :group 'offlinemap) + (defvar offlineimap-mode-map (let ((map (make-sparse-keymap))) (define-key map (kbd "q") 'offlineimap-quit) @@ -186,11 +191,15 @@ This is used when `offlineimap-mode-line-style' is set to 'symbol.") ;; "tail". (if (eq (point) (point-max)) (progn + (when offlineimap-timestamp + (insert (format-time-string offlineimap-timestamp))) (insert text) (set-marker (process-mark process) (point))) ;; But if not, let the cursor where it is, so `save-excursion'. (save-excursion (goto-char (point-max)) + (when offlineimap-timestamp + (insert (format-time-string offlineimap-timestamp))) (insert text) (set-marker (process-mark process) (point))))))))) |