 
 ; Haskell
 ; adopted from http://sequence.complete.org/node/365
-(add-to-list 'load-path "/usr/share/emacs/site-lisp/haskell-mode/")
-(require 'haskell-mode-autoloads)
-(add-to-list
-	'Info-default-directory-list
-	"/usr/share/emacs/site-lisp/haskell-mode/")
 (remove-hook 'haskell-mode-hook 'turn-on-haskell-indent)
 
 ; The "Haskell-Cabal" mode that comes built-in with haskell-mode needs some

(load "~/.emacs.d/vars")
; remove splash screen
(setq inhibit-splash-screen t)

(package-initialize)
(add-to-list 'package-archives '("melpa" . "http://melpa.milkbox.net/packages/") t)

; Define packages that we'll be using.
(defvar my/packages
	'(
	column-enforce-mode
	coffee-mode
	elscreen
	evil
	haml-mode
	haskell-mode
	hiwin
	kakapo-mode
	markdown-mode
	org
	yaml-mode
	) "Default packages")

; Install packages if they are missing.
(defun my/packages-installed-p ()
  (loop for pkg in my/packages
        when (not (package-installed-p pkg)) do (return nil)
        finally (return t)))

(unless (my/packages-installed-p)
  (message "%s" "Refreshing package database...")
  (package-refresh-contents)
  (dolist (pkg my/packages)
    (when (not (package-installed-p pkg))
      (package-install pkg))))

(require 'evil)
(evil-mode 1)

