2024-01-21 14:00:35 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitLab
|
|
|
|
, libyaml
|
|
|
|
, testers
|
|
|
|
, yx
|
|
|
|
}:
|
2023-08-30 16:19:55 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "yx";
|
|
|
|
version = "1.0.0";
|
|
|
|
|
|
|
|
src = fetchFromGitLab {
|
|
|
|
owner = "tomalok";
|
2024-01-21 13:50:47 +00:00
|
|
|
repo = "yx";
|
2023-08-30 16:19:55 +00:00
|
|
|
rev = version;
|
|
|
|
sha256 = "sha256-oY61V9xP0DwRooabzi0XtaFsQa2GwYbuvxfERXQtYcA=";
|
|
|
|
};
|
|
|
|
|
|
|
|
makeFlags = [
|
|
|
|
"PREFIX=${placeholder "out"}"
|
|
|
|
];
|
|
|
|
|
|
|
|
strictDeps = true;
|
|
|
|
|
|
|
|
buildInputs = [ libyaml ];
|
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
2024-01-21 14:00:35 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
|
|
|
package = yx;
|
|
|
|
command = "${meta.mainProgram} -v";
|
|
|
|
version = "v${yx.version}";
|
|
|
|
};
|
|
|
|
|
2023-08-30 16:19:55 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "YAML Data Extraction Tool";
|
|
|
|
homepage = "https://gitlab.com/tomalok/yx";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = with maintainers; [ twz123 ];
|
2023-12-20 02:45:17 +00:00
|
|
|
mainProgram = "yx";
|
2023-08-30 16:19:55 +00:00
|
|
|
};
|
|
|
|
}
|