From 2aaaa26710e0b8009ac9782666e736888f5c1f87 Mon Sep 17 00:00:00 2001 From: Florian Brandes Date: Thu, 14 Mar 2024 13:06:47 +0100 Subject: [PATCH] python3Packages.jsonformatter: init at 0.3.2 Signed-off-by: Florian Brandes --- .../python-modules/jsonformatter/default.nix | 31 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 33 insertions(+) create mode 100644 pkgs/development/python-modules/jsonformatter/default.nix diff --git a/pkgs/development/python-modules/jsonformatter/default.nix b/pkgs/development/python-modules/jsonformatter/default.nix new file mode 100644 index 000000000000..f800493b2c93 --- /dev/null +++ b/pkgs/development/python-modules/jsonformatter/default.nix @@ -0,0 +1,31 @@ +{ lib +, fetchFromGitHub +, buildPythonPackage +, setuptools +}: + +buildPythonPackage rec { + pname = "jsonformatter"; + version = "0.3.2"; + format = "setuptools"; + + src = fetchFromGitHub { + owner = "MyColorfulDays"; + repo = pname; + rev = "refs/tags/v${version}"; + hash = "sha256-oK419J/MIxRT+1j/5Yklj1F+4d3wuMXR8IVqJAMKPNw="; + }; + + nativeBuildInputs = [ setuptools ]; + + pythonImportsCheck = [ + "jsonformatter" + ]; + + meta = with lib; { + description = "jsonformatter is a formatter for python output json log, e.g. output LogStash needed log"; + homepage = "https://github.com/MyColorfulDays/jsonformatter"; + license = licenses.bsd2; + maintainers = with maintainers; [ gador ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 545fe4a7dae3..96fc557382e7 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6015,6 +6015,8 @@ self: super: with self; { jsonable = callPackage ../development/python-modules/jsonable { }; + jsonformatter = callPackage ../development/python-modules/jsonformatter { }; + jsonnet = buildPythonPackage { inherit (pkgs.jsonnet) name src; }; jsonpatch = callPackage ../development/python-modules/jsonpatch { };