2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, crystal
|
|
|
|
, shards
|
|
|
|
, makeWrapper
|
|
|
|
, pkg-config
|
|
|
|
, which
|
|
|
|
, openssl
|
|
|
|
, readline
|
|
|
|
, libyaml
|
|
|
|
, zlib
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
crystal.buildCrystalPackage rec {
|
|
|
|
pname = "icr";
|
2021-04-05 15:23:46 +00:00
|
|
|
version = "unstable-2021-03-14";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "crystal-community";
|
2021-02-05 17:12:51 +00:00
|
|
|
repo = "icr";
|
2021-04-05 15:23:46 +00:00
|
|
|
rev = "b6b335f40aff4c2c07d21250949935e8259f7d1b";
|
|
|
|
sha256 = "sha256-Qoy37lCdHFnMAuuqyB9uT15/RLllksFyApYAGy+RmDs=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
shardsFile = ./shards.nix;
|
|
|
|
|
|
|
|
buildInputs = [ libyaml openssl readline zlib ];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper pkg-config which ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
# tests are failing due to our sandbox
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
postFixup = ''
|
|
|
|
wrapProgram $out/bin/icr \
|
|
|
|
--prefix PATH : ${lib.makeBinPath [ crystal shards makeWrapper which ]}
|
|
|
|
'';
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Interactive console for the Crystal programming language";
|
|
|
|
homepage = "https://github.com/crystal-community/icr";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ peterhoeg ];
|
|
|
|
};
|
|
|
|
}
|