From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Edward Dodge Newsgroups: gmane.emacs.help Subject: Re: Cool and Useful LISP for the .emacs file Date: Fri, 07 Nov 2003 17:41:11 -0600 Organization: Confabulation Consulting Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1068248982 27484 80.91.224.253 (7 Nov 2003 23:49:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 7 Nov 2003 23:49:42 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Nov 08 00:49:39 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AIGME-0007mn-00 for ; Sat, 08 Nov 2003 00:49:39 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AIHGO-000776-I5 for geh-help-gnu-emacs@m.gmane.org; Fri, 07 Nov 2003 19:47:40 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!sn-xit-03!sn-xit-01!sn-post-02!sn-post-01!supernews.com!corp.supernews.com!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3.50 (darwin) Cancel-Lock: sha1:mJeMgi0CG6LtetXImmyZZHpBzUU= Original-X-Complaints-To: abuse@supernews.com Original-Lines: 25 Original-Xref: shelby.stanford.edu gnu.emacs.help:117993 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:13932 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:13932 Dan Anderson writes: > I was wondering what other people have in their .emacs file. I would > like to challenge everyone to add at least one cool tip / trick to: > > http://www.emacswiki.org/cgi-bin/wiki/DotEmacs > > -Dan My personal favorite: (defun autocompile nil "compile itself if ~/.emacs" (interactive) (if (string= (buffer-file-name) (concat default-directory ".emacs")) (byte-compile-file (buffer-file-name)))) (add-hook 'after-save-hook 'autocompile) Never byte-compile your .emacs file by hand again! -- Edward Dodge /GNU Emacs 21.3.50.1 (powerpc-apple-darwin5.5) of 2002-10-11 on G3/