I'm trying to run Emacs v22.2 on a Windows 7 computer. However, the init
file isn't loaded at start up (loading it manually with M-x load-file
works fine).
I've tried using both:
~\.emacs, ~\_emacs
~\.emacs.d.init.el
but the problem persists.
Evaluating (insert (getenv "HOME"))
returns the expected value.
Depending on how you open emacs in Windows 7, it will look in different places for the .emacs file. If call it from within a shell (in cygwin, Msys, etc) it will look in the $HOME (~) location, if you run it form the installation directory by clicking on the icon, it looks for this file in the %APPDATA% location ( usually C:\Users\your user name\AppData\Roaming ). This can lead you in a merry chase all over the place. I found that it is best to determine where you want the file to be stored, and the create symbolic links ( using windows mklink utility ) to all other possible locations.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With