blob: 2635dad2bf505a892450e0353b6f1ae32cb0fe68 (
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
{
fetchFromGitHub,
installShellFiles,
lib,
stdenv,
python3Packages,
versionCheckHook,
}:
python3Packages.buildPythonApplication rec {
pname = "pytr";
version = "0.4.10";
pyproject = true;
src = fetchFromGitHub {
owner = "pytr-org";
repo = "pytr";
tag = "v${version}";
hash = "sha256-xo/J0POH21mLm//+gpfhuxIGdKGHJpFbpL82TIDufrM=";
};
build-system = with python3Packages; [
hatchling
hatch-babel
];
dependencies = with python3Packages; [
babel
certifi
coloredlogs
cryptography
curl-cffi
packaging
pathvalidate
playwright
pygments
requests-futures
shtab
websockets
];
nativeBuildInputs = [ installShellFiles ];
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd pytr \
--bash <($out/bin/pytr completion bash) \
--zsh <($out/bin/pytr completion zsh)
'';
nativeCheckInputs = [
versionCheckHook
python3Packages.pytestCheckHook
];
pythonImportsCheck = [ "pytr" ];
meta = {
changelog = "https://github.com/pytr-org/pytr/releases/tag/${src.tag}";
description = "Use TradeRepublic in terminal and mass download all documents";
homepage = "https://github.com/pytr-org/pytr";
license = lib.licenses.mit;
mainProgram = "pytr";
maintainers = with lib.maintainers; [ dotlambda ];
};
}
|