Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nix: refactor with flakes #1827

Merged
merged 19 commits into from
May 19, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ background](https://neilmitchell.blogspot.com/2020/01/one-haskell-ide-to-rule-th
- [Using Cabal](#using-cabal)
- [Using Stack](#using-stack)
- [Using Nix](#using-nix)
- [Flakes support](#flakes-support)
- [Introduction tutorial](#introduction-tutorial)
- [Test your hacked HLS in your editor](#test-your-hacked-hls-in-your-editor)
- [Adding support for a new editor](#adding-support-for-a-new-editor)
Expand Down Expand Up @@ -807,8 +808,25 @@ $ cabal update
$ cabal build
```

##### Flakes support

If you are using nix 2.4 style command (enabled by `experimental-features = nix-command`),
you can use `nix develop` instead of `nix-shell` to enter the development shell. To enter the shell with specific GHC versions:

* `nix develop` or `nix develop #haskell-language-server-dev` - default GHC version
* `nix develop #haskell-language-server-8104-dev` - GHC 8.10.4
* `nix develop #haskell-language-server-884-dev` - GHC 8.8.4
* `nix develop #haskell-language-server-901-dev` - GHC 9.0.1

If you are looking for a Nix expression to create haskell-language-server binaries, see https://github.com/haskell/haskell-language-server/issues/122

To create binaries:

* `nix build` or `nix build #haskell-language-server` - default GHC version
* `nix build #haskell-language-server-8104` - GHC 8.10.4
* `nix build #haskell-language-server-884` - GHC 8.8.4
* `nix build #haskell-language-server-901` - GHC 9.0.1

#### Introduction tutorial

Pepeiborra [wrote an tutorial](https://github.com/pepeiborra/hls-tutorial) on writing a plugin in HLS.
Expand Down