1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 pytest-mock,
7 pytestCheckHook,
8 pythonOlder,
9}:
10
11buildPythonPackage rec {
12 pname = "shellingham";
13 version = "1.5.4";
14 format = "pyproject";
15
16 disabled = pythonOlder "3.7";
17
18 src = fetchFromGitHub {
19 owner = "sarugaku";
20 repo = "shellingham";
21 tag = version;
22 hash = "sha256-xeBo3Ok+XPrHN4nQd7M8/11leSV/8z1f7Sj33+HFVtQ=";
23 };
24
25 nativeBuildInputs = [ setuptools ];
26
27 nativeCheckInputs = [
28 pytest-mock
29 pytestCheckHook
30 ];
31
32 pythonImportsCheck = [ "shellingham" ];
33
34 meta = with lib; {
35 description = "Tool to detect the surrounding shell";
36 homepage = "https://github.com/sarugaku/shellingham";
37 changelog = "https://github.com/sarugaku/shellingham/blob/${version}/CHANGELOG.rst";
38 license = licenses.isc;
39 maintainers = with maintainers; [ mbode ];
40 };
41}