all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* .dir-locals.el
@ 2008-12-26 15:18 Eli Zaretskii
  2008-12-26 16:04 ` .dir-locals.el Eli Zaretskii
  2008-12-27 17:13 ` .dir-locals.el Dan Nicolaescu
  0 siblings, 2 replies; 14+ messages in thread
From: Eli Zaretskii @ 2008-12-26 15:18 UTC (permalink / raw)
  To: emacs-devel

This part of .dir-locals.el from today's CVS does not seem to work:

 ("lisp/mail/pmail*"
  . ((nil . ((change-log-default-name . "ChangeLog.pmail"))))))

(To see that, you will need to remove the file-local variables from
pmail*.el files, because they specify ChangeLog.pmail there as well.)

I took a look at relevant functions in files.el, and it looks like
this wasn't supposed to work with file wildcards.  This fragment from
dir-locals-collect-variables:

	  (when (and sub-file-name
		     (>= (length sub-file-name) (length key))
		     (string= key (substring sub-file-name 0 (length key))))
	    (setq variables (dir-locals-collect-variables
			     (cdr entry) root variables))))

assumes that "lisp/mail/pmail*" is a substring of "lisp/mail/pmail.el",
which of course is false because of the `*'.  The documentation of the
feature in the manual also seems to say that the intent is to specify
here a name of a _directory_ and have that apply to all the files
under that directory.

I tried to see if this works if I change "lisp/mail/pmail*" to just
"lisp/mail", and that still didn't work for an arbitrary Lisp file in
lisp/mail: typing "C-x 4 a" after visiting the file still pops up
ChangeLog, not ChangeLog.pmail.  So maybe I'm missing something here,
and the above report is bogus; apologies if that is the case.




^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2009-01-09  3:14 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-26 15:18 .dir-locals.el Eli Zaretskii
2008-12-26 16:04 ` .dir-locals.el Eli Zaretskii
2008-12-27  2:39   ` .dir-locals.el Miles Bader
2008-12-27  9:33     ` .dir-locals.el Eli Zaretskii
2008-12-27 16:43       ` .dir-locals.el Juanma Barranquero
2008-12-27 17:13 ` .dir-locals.el Dan Nicolaescu
2008-12-27 19:04   ` .dir-locals.el Eli Zaretskii
2009-01-08  0:08     ` .dir-locals.el Eric Schulte
2009-01-08  3:04       ` .dir-locals.el Kevin Rodgers
2009-01-08  5:53         ` .dir-locals.el Eric Schulte
2009-01-08 16:30       ` .dir-locals.el Stefan Monnier
2009-01-08 22:45         ` .dir-locals.el Juri Linkov
2009-01-09  3:14           ` .dir-locals.el Stefan Monnier
2009-01-09  0:30         ` .dir-locals.el Eric Schulte

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.