Function: eca-chat--format-message-for-completion

eca-chat--format-message-for-completion is a natively compiled function defined in eca-chat.el.

Signature

(eca-chat--format-message-for-completion MSG)

Documentation

Format MSG for display in completion interface.

If MSG has :timestamp, prepends [HH:MM] to the text.

Source Code

;; Defined in /nix/store/jklqzw6pzz6j4jrbv8wy0iwgi7jlrbld-emacs-packages-deps/share/emacs/site-lisp/elpa/eca-20260928.1827/eca-chat.el
(defun eca-chat--format-message-for-completion (msg)
  "Format MSG for display in completion interface.
If MSG has :timestamp, prepends [HH:MM] to the text."
  (let ((timestamp (plist-get msg :timestamp))
        (text (plist-get msg :text)))
    (if timestamp
        (format "[%s] %s"
                (format-time-string "%H:%M" timestamp)
                text)
      text)))