summary refs log tree commit diff
path: root/pkgs/development/python-modules/timetagger/default.nix
blob: 58bf190495f4f49d78c838401533c9ada3f7adbe (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
{ lib
, python3Packages
, fetchFromGitHub
, pytestCheckHook
, requests
}:

python3Packages.buildPythonPackage rec {
  pname = "timetagger";
  version = "22.1.2";

  src = fetchFromGitHub {
    owner = "almarklein";
    repo = pname;
    rev = "v${version}";
    sha256 = "0xrajx0iij7r70ch17m4y6ydyh368dn6nbjsv74pn1x8frd686rw";
  };

  meta = with lib; {
    homepage = "https://timetagger.app";
    license = licenses.gpl3;
    description = "Tag your time, get the insight";
    maintainers = with maintainers; [ matthiasbeyer ];
  };

  checkInputs = [
    pytestCheckHook
    requests
  ];

  preCheck = ''
    # https://github.com/NixOS/nixpkgs/issues/12591
    mkdir -p check-phase
    export HOME=$(pwd)/check-phase
  '';

  propagatedBuildInputs = with python3Packages; [
    asgineer
    itemdb
    jinja2
    markdown
    pscript
    pyjwt
    uvicorn
  ];

}