blob: 538ad8b0500d2368bf75505c65262664647a00af (
plain)
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
|
{
lib,
python3Packages,
fetchFromGitHub,
writableTmpDirAsHomeHook,
}:
python3Packages.buildPythonApplication (finalAttrs: {
pname = "proselint";
version = "0.16.0";
pyproject = true;
src = fetchFromGitHub {
owner = "amperser";
repo = "proselint";
tag = "v${finalAttrs.version}";
hash = "sha256-Oj5WY+YcngcaVjDq2xcnTeyvO7HnAhKdNE+h4fFa6zA=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace "uv_build>=0.7.22,<0.8.0" uv_build
'';
build-system = [ python3Packages.uv-build ];
dependencies = with python3Packages; [ google-re2 ];
# typing stubs are not needed at runtime
pythonRemoveDeps = [ "google-re2-stubs" ];
nativeCheckInputs = [
writableTmpDirAsHomeHook
]
++ (with python3Packages; [
hypothesis
pytestCheckHook
rstr
]);
pythonImportsCheck = [ "proselint" ];
meta = {
description = "Linter for prose";
mainProgram = "proselint";
homepage = "https://github.com/amperser/proselint";
changelog = "https://github.com/amperser/proselint/releases/tag/v${finalAttrs.version}/CHANGELOG.md";
license = lib.licenses.bsd3;
maintainers = [ lib.maintainers.pbsds ];
};
})
|