ansible-later: 2.0.22 -> 2.0.23
[NixPkgs.git] / pkgs / development / python-modules / shtab / default.nix
blob24a29318170ff0d64e391d04982eab0dcf272252
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , pytest-timeout
5 , pytestCheckHook
6 , pythonOlder
7 , setuptools-scm
8 , bashInteractive
9 }:
11 buildPythonPackage rec {
12   pname = "shtab";
13   version = "1.5.7";
14   format = "setuptools";
16   disabled = pythonOlder "3.7";
18   src = fetchFromGitHub {
19     owner = "iterative";
20     repo = pname;
21     rev = "refs/tags/v${version}";
22     hash = "sha256-BIUUg+Y6bbgjnIWPU/bZO2axSLSzIsRJwyu7lBVQz/Q=";
23   };
25   SETUPTOOLS_SCM_PRETEND_VERSION = version;
27   nativeBuildInputs = [
28     setuptools-scm
29   ];
31   checkInputs = [
32     bashInteractive
33     pytest-timeout
34     pytestCheckHook
35   ];
37   postPatch = ''
38     substituteInPlace setup.cfg \
39       --replace " --cov=shtab --cov-report=term-missing --cov-report=xml" ""
40   '';
42   pythonImportsCheck = [
43     "shtab"
44   ];
46   meta = with lib; {
47     description = "Module for shell tab completion of Python CLI applications";
48     homepage = "https://docs.iterative.ai/shtab/";
49     license = licenses.asl20;
50     maintainers = with maintainers; [ fab ];
51   };