1{ lib 2, attrs 3, buildPythonPackage 4, click 5, commoncode 6, dockerfile-parse 7, fetchFromGitHub 8, pytestCheckHook 9, pythonOlder 10, setuptools-scm 11}: 12 13buildPythonPackage rec { 14 pname = "container-inspector"; 15 version = "32.0.1"; 16 format = "setuptools"; 17 18 disabled = pythonOlder "3.6"; 19 20 src = fetchFromGitHub { 21 owner = "nexB"; 22 repo = pname; 23 rev = "refs/tags/v${version}"; 24 hash = "sha256-J9glnfs6l36/IQoIvE8a+Cw4B8x/6r5UeAU8+T/OiQg="; 25 }; 26 27 SETUPTOOLS_SCM_PRETEND_VERSION = version; 28 29 dontConfigure = true; 30 31 postPatch = '' 32 # PEP440 support was removed in newer setuptools, https://github.com/nexB/container-inspector/pull/51 33 substituteInPlace setup.cfg \ 34 --replace ">=3.7.*" ">=3.7" 35 ''; 36 37 nativeBuildInputs = [ 38 setuptools-scm 39 ]; 40 41 propagatedBuildInputs = [ 42 attrs 43 click 44 dockerfile-parse 45 commoncode 46 ]; 47 48 nativeCheckInputs = [ 49 pytestCheckHook 50 ]; 51 52 pythonImportsCheck = [ 53 "container_inspector" 54 ]; 55 56 meta = with lib; { 57 description = "Suite of analysis utilities and command line tools for container images"; 58 homepage = "https://github.com/nexB/container-inspector"; 59 changelog = "https://github.com/nexB/container-inspector/releases/tag/v${version}"; 60 license = with licenses; [ asl20 ]; 61 maintainers = with maintainers; [ fab ]; 62 }; 63}