[Top][All Lists]

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

Re: [h-e-w] Initialization help needed

From: Simon Green
Subject: Re: [h-e-w] Initialization help needed
Date: Thu, 6 Dec 2001 10:30:05 +0000

>>>>> "BJ" == Bingham, Jay <address@hidden> writes:

 BJ> I am trying to modularize my init files so that I can have some small
 BJ> files that contain items that wary from one system to another.  I have
 BJ> run into a problem in attempting to do this on windows.  I want to put
 BJ> the expressions that add my own directories to the load path into one of
 BJ> these small files.  However I cannot figure out how to load the file.  I
 BJ> have tried (load "$HOME/myfile.el") and (load "~/myfile.el").  In both

Try using
(load (expand-file-name "~/myfile.el"))

expand-file-name is a built-in function.

Convert filename NAME to absolute, and canonicalize it.
Second arg DEFAULT-DIRECTORY is directory to start with if NAME is relative
 (does not start with slash); if DEFAULT-DIRECTORY is nil or missing,
the current buffer's value of default-directory is used.
File name components that are `.' are removed, and 
so are file name components followed by `..', along with the `..' itself;
note that these simplifications are done without checking the resulting
file names in the file system.
An initial `~/' expands to your home directory.
An initial `~USER/' expands to USER's home directory.
See also the function `substitute-in-file-name'.

(expand-file-name NAME &optional DEFAULT-DIRECTORY)


reply via email to

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