Function: nndraft-request-associate-buffer
nndraft-request-associate-buffer is an autoloaded and byte-compiled
function defined in nndraft.el.gz.
Signature
(nndraft-request-associate-buffer GROUP)
Documentation
Associate the current buffer with some article in the draft group.
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/nndraft.el.gz
(deffoo nndraft-request-associate-buffer (group)
"Associate the current buffer with some article in the draft group."
(nndraft-open-server "")
(nndraft-request-group group)
(nndraft-possibly-change-group group)
(let ((gnus-verbose-backends nil)
(buf (current-buffer))
article file)
(with-temp-buffer
(insert-buffer-substring buf)
(setq article (nndraft-request-accept-article
group (nnoo-current-server 'nndraft) t 'noinsert)
file (nndraft-article-filename article)))
(setq buffer-file-name (expand-file-name file)
buffer-auto-save-file-name (make-auto-save-file-name))
(clear-visited-file-modtime)
(add-hook 'write-contents-functions #'nndraft-generate-headers nil t)
(add-hook 'after-save-hook #'nndraft-update-unread-articles nil t)
(message-add-action '(nndraft-update-unread-articles)
'exit 'postpone 'kill)
article))