|
From: | Kevin Rodgers |
Subject: | Re: Fire defun by typing keyword |
Date: | Tue, 29 Oct 2013 21:23:15 -0600 |
User-agent: | Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4; en-US; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20 |
On 10/29/13 8:38 PM, Emanuel Berg wrote:
Is it possible to fire off a defun by typing a specific keyword? Sort of like the way abbrev works? For example, I have a defun like this (defun date () (interactive) (insert-shell-command "my_date") ) where "my_date" is a script to format output from /bin/date. Now, my idea is to hook it to a keyword, say "thedate". Again, it would work just as abbrev, only instead of a table lookup and replace, it would trigger a defun.
I'd start with `C-h f abbrev-expand-functions' -- Kevin Rodgers Denver, Colorado, USA
[Prev in Thread] | Current Thread | [Next in Thread] |