depot/third_party/nixpkgs/pkgs/tools/security/zeekscript/default.nix
Default email 5e9e1146e1 Project import generated by Copybara.
GitOrigin-RevId: 18036c0be90f4e308ae3ebcab0e14aae0336fe42
2023-08-05 00:07:22 +02:00

40 lines
850 B
Nix

{ lib
, python3
, fetchPypi
}:
python3.pkgs.buildPythonApplication rec {
pname = "zeekscript";
version = "1.2.1";
format = "pyproject";
src = fetchPypi {
inherit pname version;
hash = "sha256-LogI9sJHvLN5WHJGdW47D09XZInKln/I2hNmG62d1JU=";
};
postPatch = ''
sed -i '/name = "zeekscript"/a version = "${version}"' pyproject.toml
'';
nativeBuildInputs = with python3.pkgs; [
setuptools
wheel
];
propagatedBuildInputs = with python3.pkgs; [
tree-sitter
];
pythonImportsCheck = [
"zeekscript"
];
meta = with lib; {
description = "A Zeek script formatter and analyzer";
homepage = "https://github.com/zeek/zeekscript";
changelog = "https://github.com/zeek/zeekscript/blob/v${version}/CHANGES";
license = licenses.bsd3;
maintainers = with maintainers; [ fab tobim ];
};
}