views:

133

answers:

1

I just downloaded the Haskell and J modes off of SourceForge, and I'm having trouble figuring out how to make them interface with emacs 23. Google searches yield detailed instructions for emacs 22, but it looks like changes have been made that make it hard to figure out where I'm supposed to stick the source files. The internal documentation seems to assume more experience with emacs internals than I currently have, and the problem has resisted solution for several days. Does anyone know how to get these modes up and running?

EDIT: Thanks to Untwisted for supplying the answer. Ultimately, my real problems were these:

1) I didn't know that .emacs was invisible to the OSX finder but was visible through the terminal.

2) It never occurred to me that I could modify .emacs while an instance of emacs was running.

Once I realized that those were my problems, I used C-x C-f to open ~/.emacs, copied the text of Untwisted's fix, and modified it to reflect my personal file paths. After that, everything worked.

+2  A: 

Basically you need to put the .el files somewhere (I keep mine in ~/.emacs_extras/haskell-mode/ ), and edit your ~/.emacs file to load Haskell mode when appropriate. Example of a ~/.emacs file:

(load "~/.emacs_addons/haskell-mode/haskell-site-file")
(add-hook 'haskell-mode-hook 'turn-on-haskell-doc-mode)
(add-hook 'haskell-mode-hook 'turn-on-haskell-indentation)

That should make Haskell mode work. For more details, other options, etc: http://www.haskell.org/haskellwiki/Haskell_mode_for_Emacs

untwisted
So is the .emacs file inside the emacs23 package, or does it go into an external file path during installation? Figuring out (where the .emacs file is/what it's called/how to change it) has been a significant part of my problem.
estanford
Found it. (It's hidden in the OS X finder, but not to ls -al in the Terminal.) Now all I have to do is figure out how to convince the file that I have read/write permissions...
estanford
Ha! Got it. I should be good from here.
estanford