Skip to content

Commit

Permalink
haskell: Parameterize stack package
Browse files Browse the repository at this point in the history
  • Loading branch information
sestrella committed Jun 3, 2023
1 parent b5d2da4 commit 17ea82c
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/modules/languages/haskell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,25 @@ in
Haskell language server to use.
'';
};

stack = lib.mkOption {
type = lib.types.nullOr lib.types.package;
default = pkgs.stack;
defaultText = "pkgs.stack";
description = ''
Haskell stack to use.
'';
};
};

config = lib.mkIf cfg.enable {
packages = with pkgs; [
cfg.package
cfg.languageServer
stack
cabal-install
zlib
hpack
];
]
++ (lib.optional (cfg.stack != null) cfg.stack);
};
}

0 comments on commit 17ea82c

Please sign in to comment.