1{
2 lib,
3 fetchFromGitHub,
4 crystal,
5 libxml2,
6 openssl,
7}:
8
9crystal.buildCrystalPackage rec {
10 pname = "mint";
11 version = "0.24.1";
12
13 src = fetchFromGitHub {
14 owner = "mint-lang";
15 repo = "mint";
16 tag = version;
17 hash = "sha256-gMR/FUp/pOC0TQy6ENH3pIxK43hrHEciT17aGqXVKc8=";
18 };
19
20 format = "shards";
21
22 # Update with
23 # nix-shell -p crystal2nix --run crystal2nix
24 # with mint's shard.lock file in the current directory
25 shardsFile = ./shards.nix;
26
27 nativeBuildInputs = [
28 libxml2 # xmllint
29 ];
30
31 buildInputs = [ openssl ];
32
33 preCheck = ''
34 substituteInPlace spec/spec_helper.cr \
35 --replace-fail "clear_env: true" "clear_env: false"
36 '';
37
38 meta = {
39 description = "Refreshing language for the front-end web";
40 mainProgram = "mint";
41 homepage = "https://www.mint-lang.com/";
42 license = lib.licenses.bsd3;
43 maintainers = with lib.maintainers; [ manveru ];
44 };
45}