Disclaimer: this project is still in development, this is work in
progress. Please report and improve this documentation if you encounter issues.
### Stack setup
You need to install stack first:
```shell
curl -sSL https://get.haskellstack.org/ | sh
```
Verify the installation is complete with
```shell
stack --version
```
### With Nix setup
First install [nix](https://nixos.org/guides/install-nix.html):
```shell
sh < (curl -L https://nixos.org/nix/install)--daemon
```
Verify the installation is complete
```shell
$ nix-env
nix-env (Nix) 2.3.12
```
And just build:
``` sh
stack --nix build --fast
```
### Build Core Code
NOTE: Default build (with optimizations) requires large amounts of RAM (16GB at least). To avoid heavy compilation times and swapping out your machine, it is recommended to `stack build` with the `--fast-` flag, i.e.:
NOTE: Default build (with optimizations) requires large amounts of RAM
(16GB at least). To avoid heavy compilation times and swapping out your
machine, it is recommended to `stack build` with the `--fast-` flag,
i.e.:
``` sh
stack --docker build --fast
stack --nix build --fast
```
or
``` sh
stack --nix build --fast
stack --docker build --fast
```
This might be related to the [broken Swagger `-O2` issue](https://github.com/haskell-servant/servant/issues/986).