blob: 07710e18466bbc7c3c0fbffe5decdc991fe449a6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
flit-core,
fzf,
packaging,
pytestCheckHook,
pythonOlder,
setuptools,
}:
buildPythonPackage rec {
pname = "iterfzf";
version = "1.4.0.54.3";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "dahlia";
repo = "iterfzf";
rev = "refs/tags/${version}";
hash = "sha256-DvEFCHK+1TA/TTXG//hvXXbRclBkelonA3QsB4h7eRM=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail 'dynamic = ["version"]' 'version = "${version}"' \
--replace-fail 'backend-path = ["."]' '# backend-path = ["."]' \
--replace-fail 'build-backend = "build_dist"' '# build-backend = "build_dist"'
substituteInPlace iterfzf/test_iterfzf.py \
--replace-fail 'executable="fzf"' 'executable="${fzf}/bin/fzf"'
'';
build-system = [
flit-core
setuptools
packaging
];
dependencies = [ fzf ];
nativeCheckInputs = [ pytestCheckHook ];
disabledTests = [
# AttributeError
"test_no_query"
"test_select_one_ambiguous"
];
pythonImportsCheck = [ "iterfzf" ];
meta = with lib; {
description = "Pythonic interface to fzf, a CLI fuzzy finder";
homepage = "https://github.com/dahlia/iterfzf";
changelog = "https://github.com/dahlia/iterfzf/releases/tag/${version}";
license = licenses.gpl3Only;
maintainers = with maintainers; [ fab ];
};
}
|