1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, fetchpatch 5, click 6, pytestCheckHook 7}: 8 9buildPythonPackage rec { 10 pname = "click-default-group"; 11 version = "1.2.2"; 12 13 # No tests in Pypi tarball 14 src = fetchFromGitHub { 15 owner = "click-contrib"; 16 repo = "click-default-group"; 17 rev = "v${version}"; 18 sha256 = "0nk39lmkn208w8kvq6f4h3a6qzxrrvxixahpips6ik3zflbkss86"; 19 }; 20 21 patches = [ 22 # make tests compatible with click 8 23 (fetchpatch { 24 url = "https://github.com/click-contrib/click-default-group/commit/9415c77d05cf7d16876e7d70a49a41a6189983b4.patch"; 25 sha256 = "1czzma8nmwyxhwhnr8rfw5bjw6d46b3s5r5bfb8ly3sjwqjlwhw2"; 26 }) 27 ]; 28 29 propagatedBuildInputs = [ click ]; 30 31 checkInputs = [ pytestCheckHook ]; 32 33 pythonImportsCheck = [ "click_default_group" ]; 34 35 meta = with lib; { 36 homepage = "https://github.com/click-contrib/click-default-group"; 37 description = "Group to invoke a command without explicit subcommand name"; 38 license = licenses.bsd3; 39 maintainers = with maintainers; [ jakewaksbaum ]; 40 }; 41}