summary refs log tree commit diff
path: root/pkgs/applications/office/envelope/default.nix
blob: 2a2f55a27a40ea6f416d04a5529980b02751e27e (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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
{ stdenv
, fetchFromGitHub
, fetchpatch
, meson
, ninja
, pkgconfig
, pantheon
, python3
, vala
, appstream-glib
, desktop-file-utils
, gettext
, glib
, gtk3
, libgee
, sqlite
, wrapGAppsHook
}:

stdenv.mkDerivation rec {
  pname = "envelope";
  version = "0.0.4";

  src = fetchFromGitHub {
    owner = "cjfloss";
    repo = pname;
    rev = version;
    sha256 = "111lq1gijcm7qwpac09q11ymwiw2x3m12a28ki52f28fb1amvffc";
  };

  nativeBuildInputs = [
    appstream-glib
    desktop-file-utils
    gettext
    meson
    ninja
    vala
    pkgconfig
    python3
    wrapGAppsHook
  ];

  buildInputs = [
    glib
    gtk3
    libgee
    pantheon.granite
    sqlite
  ];

  doCheck = true;

  patches = [
    # Fix AppData Validation.
    # https://github.com/cjfloss/envelope/pull/59
    (fetchpatch {
      url = "https://github.com/cjfloss/envelope/commit/b6a28eced89b8f944479fcc695aebfb9aae0c691.patch";
      sha256 = "11znc8z52kl893n3gmmdpnp3y4vpzmb263m5gp0qxbl3xykq2wzr";
    })
  ];

  postPatch = ''
    chmod +x data/post_install.py
    patchShebangs data/post_install.py
  '';

  passthru = {
    updateScript = pantheon.updateScript {
      attrPath = pname;
    };
  };

  meta = with stdenv.lib; {
    description = "Personal finance manager for elementary OS";
    homepage = "https://github.com/cjfloss/envelope";
    maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
    platforms = platforms.linux;
    license = licenses.gpl3Plus;
  };
}