Function: erc-echo-timestamp

erc-echo-timestamp is an interactive and byte-compiled function defined in erc-stamp.el.gz.

Signature

(erc-echo-timestamp DIR STAMP &optional ZONE)

Documentation

Display timestamp of message at point in echo area.

Interactively, interpret a numeric prefix as a ZONE offset in hours (or seconds, if its abs value is larger than 14), and interpret a "raw" prefix as UTC. To specify a zone for use with the option erc-echo-timestamps, see the companion option erc-echo-timestamp-zone.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/erc/erc-stamp.el.gz
(defun erc-echo-timestamp (dir stamp &optional zone)
  "Display timestamp of message at point in echo area.
Interactively, interpret a numeric prefix as a ZONE offset in
hours (or seconds, if its abs value is larger than 14), and
interpret a \"raw\" prefix as UTC.  To specify a zone for use
with the option `erc-echo-timestamps', see the companion option
`erc-echo-timestamp-zone'."
  (interactive (list nil (erc--get-inserted-msg-prop 'erc--ts)
                     (pcase current-prefix-arg
                       ((and (pred numberp) v)
                        (if (<= (abs v) 14) (* v 3600) v))
                       (`(,_) t))))
  (if (and stamp (or (null dir) (and erc-echo-timestamps (eq 'entered dir))))
      (progn
        (setq erc-stamp--last-stamp stamp)
        (message (format-time-string erc-echo-timestamp-format
                                     stamp (or zone erc-echo-timestamp-zone))))
    (when (and erc-echo-timestamps (eq 'left dir))
      (setq erc-stamp--last-stamp nil))))