From: jadamson@partners.org (Joel J. Adamson)
To: help-gnu-emacs@gnu.org
Subject: Re: how to use "if" in lisp
Date: Fri, 16 Nov 2007 09:35:41 -0500 [thread overview]
Message-ID: <87k5oigsw2.fsf@W0053328.mgh.harvard.edu> (raw)
In-Reply-To: 874pfnfhwu.fsf@supermath.math.umn
Teng Wang <twang.umn@gmail.com> writes:
> Thank you for your help.
>
> I think about it for a while. I think my design is sort of
> nonsense. Since .emacs only be loaded once when start up. When I
> change the buffer, it cannot run again.
>
> So now, I am wondering: is there any way to make it run on fly?
(defun this-be-a-function ()
(interactive)
(message "This be an interactive function"))
The "(interactive)" in the second line makes it callable by name,
i.e. "M-x this-be-a-function" prints "This be an interactive function"
in the minibuffer.
The Introduction to Emacs Lisp and Elisp manuals are really helpful, and
easy to read.
Joel
--
Joel J. Adamson
Biostatistician
Pediatric Psychopharmacology Research Unit
Massachusetts General Hospital
Boston, MA 02114
(617) 643-1432
(303) 880-3109
next prev parent reply other threads:[~2007-11-16 14:35 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-15 18:01 how to use "if" in lisp Teng Wang
2007-11-15 18:08 ` Mirko
2007-11-15 18:30 ` Joel J. Adamson
2007-11-15 18:37 ` Joel J. Adamson
2007-11-15 19:05 ` Teng Wang
2007-11-15 19:16 ` Teng Wang
2007-11-16 1:04 ` Xah Lee
2007-11-16 14:35 ` Joel J. Adamson [this message]
2007-11-17 1:19 ` Tim X
2007-11-17 4:56 ` Teng Wang
2007-11-15 19:32 ` Sebastian Tennant
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87k5oigsw2.fsf@W0053328.mgh.harvard.edu \
--to=jadamson@partners.org \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.