To get started you need to have Haskell compiler to be installed, as well as some IDE support.
In this course we will use stack - a Haskell build tool that also takes care of installing GHC (Haskell compiler) and package management.
- Create
~/.local/binand add it to yourPATH. - Install stack:
curl -sSL https://get.haskellstack.org/ | shorbrew install haskell-stack - Watch if there were any warnings about
PATH - [Optional] Run
stack setupandstack ghcito verify that you can run Haskell on your machine.
We will also use Atom as an IDE with some Haskell-related plugins.
There are number of options to use as and IDE for Haskell. Most popular are Emacs (Spacemacs), Atom and VSCode.
There is a Haskforce plugin for Intellij Idea too.
- Install Atom (click and follow the instructions)
- Install useful plugins:
apm install file-icons linter - Install Haskell dev tools:
stack install ghc-mod hindent hlint stylish-haskell hasktags. - Verify installation:
ghc-mod --version. - Install
Atompackages for Haskell:
apm install ide-haskell language-haskell haskell-ghc-mod linter-hlint autocomplete-haskell ide-haskell-hasktags.
- Install VSCode
- Open
VSCodeand make it register itself inPATH:- Click
CMD+SHIFT+P - Type
shell - Select
Install 'code' command in PATH
- Click
- Install useful pluging:
- in UI:
CMD+SHIFT+Pand selectInstall Extensions - Select
file-iconsand clickinstall
- in UI:
- Install plugins for Haskell development:
CMD+SHIFT+P,Install Extensions- type
haskellto filter a list - install
Haskell ghc-modandhaskell-linter - look at https://marketplace.visualstudio.com/items?itemName=hoovercj.vscode-ghc-mod