[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: relative load-file

From: Stefan Monnier
Subject: Re: relative load-file
Date: Wed, 11 Nov 2009 18:06:07 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux)

> Unfortunately this doesn't work either because load-file-name might
> sometimes be nil.  For example

Of course in the case of M-C-x or eval-buffer, it will be nil.
If you care about that case, refine it to

   (load (expand-file-name <foo> (if load-file-name
                                     (file-name-directory load-file-name))))

-- Stefan

reply via email to

[Prev in Thread] Current Thread [Next in Thread]