From 51f6d18c054780f0f4b5efd0291bbc084066b5be Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 19 May 2025 19:31:38 +0200 Subject: [PATCH 1/2] deepsecrets: refactor --- pkgs/tools/security/deepsecrets/default.nix | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/pkgs/tools/security/deepsecrets/default.nix b/pkgs/tools/security/deepsecrets/default.nix index 1238d51b23bc..d0a7813e2eba 100644 --- a/pkgs/tools/security/deepsecrets/default.nix +++ b/pkgs/tools/security/deepsecrets/default.nix @@ -22,9 +22,7 @@ python3.pkgs.buildPythonApplication rec { "mmh3" ]; - build-system = with python3.pkgs; [ - poetry-core - ]; + build-system = with python3.pkgs; [ poetry-core ]; dependencies = with python3.pkgs; [ dotwiz @@ -36,13 +34,7 @@ python3.pkgs.buildPythonApplication rec { regex ]; - pythonImportsCheck = [ - "deepsecrets" - ]; - - nativeCheckInputs = with python3.pkgs; [ - pytestCheckHook - ]; + nativeCheckInputs = with python3.pkgs; [ pytestCheckHook ]; disabledTests = [ # assumes package is built in /app (docker?), and not /build/${src.name} (nix sandbox) @@ -51,12 +43,14 @@ python3.pkgs.buildPythonApplication rec { "test_basic_info" ]; + pythonImportsCheck = [ "deepsecrets" ]; + meta = { description = "Secrets scanner that understands code"; - mainProgram = "deepsecrets"; homepage = "https://github.com/avito-tech/deepsecrets"; changelog = "https://github.com/avito-tech/deepsecrets/releases/tag/v${version}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ fab ]; + mainProgram = "deepsecrets"; }; } From 075f82fe32291acc1d434152f094478dd83f4d2e Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 19 May 2025 19:32:07 +0200 Subject: [PATCH 2/2] deepsecrets: mark as broekn on darwin --- pkgs/tools/security/deepsecrets/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/tools/security/deepsecrets/default.nix b/pkgs/tools/security/deepsecrets/default.nix index d0a7813e2eba..7936c303b7e0 100644 --- a/pkgs/tools/security/deepsecrets/default.nix +++ b/pkgs/tools/security/deepsecrets/default.nix @@ -1,5 +1,6 @@ { lib, + stdenv, python3, fetchFromGitHub, }: @@ -52,5 +53,6 @@ python3.pkgs.buildPythonApplication rec { license = lib.licenses.mit; maintainers = with lib.maintainers; [ fab ]; mainProgram = "deepsecrets"; + broken = stdenv.hostPlatform.isDarwin; }; }