A minimal emacs configuration for haskell programming using dante and friends.
- Coming from Vim? Try the evil branch which includes vim key bindings
Package management approach is based on this tutorial.
To get a haskell compiler, I recommend downloading Stack and running
stack setup to install GHC.
stack setup does not install ghci in the global environment, you may want to run this command to create a
~/.local/bin/ghci executable that will run with the global stack environment:
if [ ! -f ~/.local/bin/ghci ]; then echo "#\!/bin/bash" > ~/.local/bin/ghci echo "stack exec -- ghci $@" >> ~/.local/bin/ghci chmod +x ~/.local/bin/ghci fi
To install this configuration, clone the repository and place the following files at your home directory:
.emacs- emacs will call this file first which will trigger the whole thing. Also contains a few convenient tweaks.
.emacs.d/my-packages.el- contains the list of packages to install when starting emacs
.emacs.d/my-loadpackages.el- defines how to enable and setup the packages we use
WARNING: Backup your changes to all your emacs related files before running the following commands as they will override your files!
So the steps are:
git clone https://github.com/soupi/minimal-haskell-emacs cp minimal-haskell-emacs/.emacs ~/ cp -r minimal-haskell-emacs/.emacs.d ~/
Now just run Emacs and start hacking!
Extra useful shortcuts:
F8- Toggle neotree
F7- Open buffers list
C-~- next / previous buffer
C-tab- switch window
M-<arrow>- move to window in direction
C-:- In a haskell buffer, search this word in hoogle