nixpkgs-suyu/pkgs/development/tools/oq/default.nix
2021-12-25 13:20:50 +00:00

37 lines
763 B
Nix

{ lib
, fetchFromGitHub
, crystal
, jq
, libxml2
, makeWrapper
}:
crystal.buildCrystalPackage rec {
pname = "oq";
version = "1.3.1";
src = fetchFromGitHub {
owner = "Blacksmoke16";
repo = pname;
rev = "v${version}";
sha256 = "sha256-La2oi+r9sCmnacgjQe+LcTQ7EXKorSoTTD4LhNtQsYk=";
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ jq libxml2 ];
format = "shards";
postInstall = ''
wrapProgram "$out/bin/oq" \
--prefix PATH : "${lib.makeBinPath [ jq ]}"
'';
meta = with lib; {
description = "A performant, and portable jq wrapper";
homepage = "https://blacksmoke16.github.io/oq/";
license = licenses.mit;
maintainers = with maintainers; [ Br1ght0ne ];
platforms = platforms.unix;
};
}