Haskell
Firstly install the haskell-stack chocolatey package:
choco install -y haskell-stack
For me that perfectly installed haskell and meant that I could run stack commands and have stack ghci running in a DOS prompt.
Emacs
Chocolatey has an Emacs package:
choco install -y emacs
This puts the emacs binaries into the chocolatey bin directory. Then the .emacs file and the .emacs.d directory go into %APPDATA%.
This installs an Emacs windows program. I wondered if there was a DOS version similar to Vim. There is an Emacs For DOS – but this isn’t part of the Chocolatey package, which comes from the GNU Emacs FTP directory.
Intero
The haskell project have a new integration with Emacs. I have to say this installed remarkably easy. The only problem I had was that I’d put a bad config into %APPDATA%\stack\config.yaml and this created errors – that were well explained in Emacs.
It’s not 100% clear how you get things to work though. Bare in mind I’ve never used Emacs before today.
I have managed to get Haskell setup and working, which came with stack.
Following the Intero guide, the installation of the package was easy enough – just edit the %APPDATA%\emacs.d file. I restarted Emacs and the Intero package installed itself without errors.
Following the guide further I ran the stack new intro-demo command in a directory. This created the intero-demo directory and put everything in it. If you then ‘File > Open Directory’ in Emacs to open the intero-demo directory. Opening Setup.hs had the affect of getting Intero to install itself.
At this point things were actually working – but it wasn’t obvious the the error as you type checking was happening because it was erroring at the very first command of the Setup.hs
However if you open up a new Haskell file in the directory it should start doing error checking on the fly.

Leave a comment