From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: drmemory@starband.net (DrMemory) Newsgroups: gmane.emacs.help Subject: Re: auto-insert-alist Date: Thu, 15 Jul 2004 21:39:32 GMT Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: <40F573E4.4020400@yahoo.com> <%WfJc.12$VQ1.7@fe25.usenetserver.com> <40F6A8A3.5050908@yahoo.com> NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1089927777 15034 80.91.224.253 (15 Jul 2004 21:42:57 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 15 Jul 2004 21:42:57 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Jul 15 23:42:49 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BlE08-0007y0-00 for ; Thu, 15 Jul 2004 23:42:49 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BlE2d-0006TK-Sn for geh-help-gnu-emacs@m.gmane.org; Thu, 15 Jul 2004 17:45:23 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!logbridge.uoregon.edu!pln-e!lotsanews.com!news.moat.net!border1.nntp.sjc.giganews.com!nntp.giganews.com!sjc1.usenetserver.com!news.usenetserver.com!fe25.usenetserver.com.POSTED!53ab2750!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: slrn/0.9.5.7 (UNIX) Original-Lines: 39 Original-X-Complaints-To: abuse@usenetserver.com X-Abuse-Info: Please be sure to forward a copy of ALL headers X-Abuse-Info: Otherwise we will be unable to process your complaint properly. Original-NNTP-Posting-Date: Thu, 15 Jul 2004 17:39:32 EDT Original-Xref: shelby.stanford.edu gnu.emacs.help:124319 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 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:19654 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:19654 On Thu, 15 Jul 2004 09:54:11 -0600, Kevin Rodgers wrote: > >I think it is a bug. The documentation is very clear: > >| A list specifying text to insert by default into a new file. >| Elements look like (CONDITION . ACTION) or ((CONDITION . DESCRIPTION) . ACTION). >| CONDITION maybe a regexp that must match the new file's name, or it may be >| a symbol that must match the major mode for this element to apply. >| Only the first matching element is effective. >| Optional DESCRIPTION is a string for filling `auto-insert-prompt'. >| ACTION may be a skeleton to insert (see `skeleton-insert'), an absolute >| file-name or one relative to `auto-insert-directory' or a function to call. >| ACTION may also be a vector containing several successive single actions as >| described above, e.g. ["header.insert" date-and-author-update]. > I'm sort of an elisp novice, but this seems to be the relevant code from autoinsert.el: ;; Now, if we found something, do it (and action (if (stringp action) (file-readable-p (concat auto-insert-directory action)) t) (if auto-insert-query (or (if (eq auto-insert-query 'function) (eq this-command 'auto-insert)) (y-or-n-p (format auto-insert-prompt desc))) t) (mapcar (lambda (action) (if (stringp action) (if (file-readable-p (setq action (concat auto-insert-directory action))) (insert-file-contents action)) [...] Looks to me as if the "absolute filename" option is illusory, and any file to be inserted would have to be given relative to auto-insert-directory.