summaryrefslogtreecommitdiff
path: root/2024/OCaml/shell.nix
blob: aa955b6d5fedd96a1e6cfa3b6ca729f487233530 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{ }:
let
  config = {
    allowUnfree = true;
  };
  pkgs = import <nixpkgs> { inherit config; };

  # choose the ocaml version you want to use
  ocamlPackages = pkgs.ocaml-ng.ocamlPackages_5_2;
in
pkgs.mkShell {
  # build tools
  nativeBuildInputs = with ocamlPackages; [
    pkgs.opam
    ocaml
    findlib
    dune_3
  ];
  # dependencies
  buildInputs = with ocamlPackages; [
    bisect_ppx
    findlib
    menhir
    ocaml-lsp
    earlybird
    ocamlformat
    ocamlgraph
    odoc
    ounit2
    re2
    utop

    pkgs.gh # GitHub CLI

    # Fallback language
    pkgs.php84
    pkgs.intelephense
    pkgs.php84Packages.php-cs-fixer
    pkgs.php84Packages.phpstan
    pkgs.nodejs_18
  ];
}