<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet href="/assets/rss.xsl" type="text/xsl"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
>
<channel>
	<title>Sacha Chua - tag - lisp</title>
	<atom:link href="https://sachachua.com/blog/tag/lisp/feed/index.xml" rel="self" type="application/rss+xml" />
	<atom:link href="https://sachachua.com/blog/tag/lisp" rel="alternate" type="text/html" />
	<link>https://sachachua.com/blog/tag/lisp/feed/index.xml</link>
	<description>Emacs, sketches, and life</description>
	<lastBuildDate>Thu, 02 Apr 2026 12:05:16 GMT</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>daily</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>11ty</generator>
  <item>
		<title>More Emacs fun: Composing mail to everyone with notes</title>
		<link>https://sachachua.com/blog/2006/09/more-emacs-fun-composing-mail-to-everyone-with-notes/</link>
		<dc:creator><![CDATA[Sacha Chua]]></dc:creator>
		<pubDate>Fri, 01 Sep 2006 16:24:00 GMT</pubDate>
    <category>bbdb</category>
<category>emacs</category>
		<guid isPermaLink="false">https://sachachua.com/blog/?p=3817</guid>
		<description><![CDATA[<pre class="example">
(defun sacha/compose-mail-to-everyone (&optional subject)
  (mapc (lambda (rec)
          (setq rec (car rec))
          (when (bbdb-record-net rec)
            (bbdb-send-mail rec subject)
            (save-excursion
              (message-goto-signature)
              (forward-line -2)
              (insert "\n&#45;&#45;&#45;&#45; NOTES &#45;&#45;-\n" (bbdb-record-notes rec) "\n"))))
        bbdb-records))

(defun sacha/gnus-delete-notes ()
  (goto-char (point-min))
  (when (re-search-forward "^&#45;&#45;- NOTES &#45;&#45;-" nil t)
    (goto-char (match-beginning 0))
    (message-kill-to-signature)))
(add-hook 'message-send-hook 'sacha/gnus-delete-notes)
</pre>


<p>You can <a href="mailto:sacha@sachachua.com?subject=Comment%20on%20https%3A%2F%2Fsachachua.com%2Fblog%2F2006%2F09%2Fmore-emacs-fun-composing-mail-to-everyone-with-notes%2F&body=Name%20you%20want%20to%20be%20credited%20by%20(if%20any)%3A%20%0AMessage%3A%20%0ACan%20I%20share%20your%20comment%20so%20other%20people%20can%20learn%20from%20it%3F%20Yes%2FNo%0A">e-mail me at sacha@sachachua.com</a>.</p>]]></description>
		</item><item>
		<title>Emacs: Keep track of messages sent</title>
		<link>https://sachachua.com/blog/2006/09/emacs-keep-track-of-messages-sent/</link>
		<dc:creator><![CDATA[Sacha Chua]]></dc:creator>
		<pubDate>Fri, 01 Sep 2006 16:06:00 GMT</pubDate>
    <category>bbdb</category>
<category>emacs</category>
		<guid isPermaLink="false">https://sachachua.com/blog/?p=3819</guid>
		<description><![CDATA[<p>Because a Big Brother Database of my contacts isn't complete if I<br>
don't keep track of what e-mail I sent them and when I sent it, this<br>
bit of Emacs Lisp code adds Gnus subjects to the BBDB records of the<br>
people to whom I sent e-mail.</p>
<pre class="example">
(defun sacha/gnus-add-subject-to-bbdb-record ()
  "Add datestamped subject note for each person this message has been sent to."
  (let* ((subject (concat (planner-today)
                          ": E-mail: " (message-fetch-field "Subject") "\n"))
         (bbdb-get-addresses-headers
          (list (assoc 'recipients bbdb-get-addresses-headers)))
         records)
    (setq records
          (bbdb-update-records
           (bbdb-get-addresses nil gnus-ignored-from-addresses 'gnus-fetch-field)
           nil nil))
    (mapc (lambda (rec)
            (bbdb-record-set-notes rec
                                   (concat subject
                                           (bbdb-record-notes rec))))
            records)))
(add-hook 'message-send-hook 'sacha/gnus-add-subject-to-bbdb-record)
</pre>
<p>It should be really easy to set up Gnus to expand some kind of<br>
!followup macro into a TODO item in my planner and an &#8220;I hope to hear<br>
from you by &#8230;.&#8221;. Ridiculously easy with Emacs Lisp and an insanely<br>
customizable editor, but I might not have enough battery life. I've<br>
got 28 minutes, and then I'm off PC for a while.</p>

<p><a href="https://sachachua.com/mnt/media/sacha/notebook/emacs/dotgnus.el">/mnt/media/sacha/notebook/emacs/dotgnus.el</a></p>

<p>You can <a href="mailto:sacha@sachachua.com?subject=Comment%20on%20https%3A%2F%2Fsachachua.com%2Fblog%2F2006%2F09%2Femacs-keep-track-of-messages-sent%2F&body=Name%20you%20want%20to%20be%20credited%20by%20(if%20any)%3A%20%0AMessage%3A%20%0ACan%20I%20share%20your%20comment%20so%20other%20people%20can%20learn%20from%20it%3F%20Yes%2FNo%0A">e-mail me at sacha@sachachua.com</a>.</p>]]></description>
		</item>
	</channel>
</rss>