blob: 1e3b2e7661d72d4f6403e9a33db99ec125bc9745 (
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
|
{
lib,
buildPythonPackage,
fetchPypi,
writableTmpDirAsHomeHook,
setuptools,
lxml,
pymupdf,
pysrt,
translatehtml,
}:
buildPythonPackage rec {
pname = "argos-translate-files";
version = "1.4.1";
pyproject = true;
src = fetchPypi {
inherit pname version;
hash = "sha256-9ufNuExfyW3gr8+pIpp6Ie03e0hE4l3l3kk6EiVH0x8=";
};
build-system = [ setuptools ];
dependencies = [
lxml
pymupdf
pysrt
translatehtml
];
nativeCheckInputs = [
# pythonImportsCheck needs a home dir for argostranslatefiles
writableTmpDirAsHomeHook
];
postPatch = ''
ln -s */requires.txt requirements.txt
'';
pythonImportsCheck = [ "argostranslatefiles" ];
meta = {
description = "Translate files using Argos Translate";
homepage = "https://www.argosopentech.com";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ misuzu ];
};
}
|