Function: rmail:msg-id-get

rmail:msg-id-get is a byte-compiled function defined in hmail.el.

Signature

(rmail:msg-id-get)

Documentation

Return current msg id for an hmail:reader buffer as a string, else nil.

Signals error when current mail reader is not supported.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hmail.el
(defun rmail:msg-id-get ()
  "Return current msg id for an `hmail:reader' buffer as a string, else nil.
Signals error when current mail reader is not supported."
  (let* ((reader (symbol-name hmail:reader))
	 ;; (toggled)
	 )
    (unless (fboundp 'rmail:msg-hdrs-full)
      (error "(rmail:msg-id-get): Invalid mail reader: %s" reader))
    (save-excursion
      (unwind-protect
	  (progn
	    ;; (setq toggled (rmail:msg-hdrs-full nil))
	    (goto-char (point-min))
	    (when (re-search-forward (concat rmail:msg-hdr-prefix "\\(.+\\)"))
	      ;; Found matching msg
	      (buffer-substring (match-beginning 2) (match-end 2))))
	;; (rmail:msg-hdrs-full toggled)
	()))))