help-gnu-emacs
[Top][All Lists]
Advanced

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

directory specific configuration


From: giampi
Subject: directory specific configuration
Date: Tue, 21 Jul 2009 03:30:51 -0700 (PDT)

Hi all,
short version of the question: is there a way to make emacs read (besides
the local ~/.emacs file) also a directory specific .emacs file, in case that
file exists?

long version: I use emacs to write latex files. I often use different
languages and therefore would like to use different dictionaries in ispell.
I also often split the document in several tex files, so, every time I have
to set the dictionary manually for each file. Each document is in a
different directory, so it would be practical for me to have an automatic
way to always start emacs with the right dictionary depending on the
directory I run from (or, better, depending on the location of the file I
open).

I bet this would require just a few lines of lisp in ~/.emacs that do:
1) get directory of the file I'm opening
2) check if a .emacs file exists for that directory
3) source the .emacs file
Unfortunately I'm no lisp programmer, so any help would be appreciated.

Thank you!
Giampiero

If it is relevant, I'm using GNU Emacs 23.0.91.1 on an Ubuntu 9.04 machine
-- 
View this message in context: 
http://www.nabble.com/directory-specific-configuration-tp24585256p24585256.html
Sent from the Emacs - Help mailing list archive at Nabble.com.





reply via email to

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