1{
2 lib,
3 buildPythonApplication,
4 fetchFromGitHub,
5 gdk-pixbuf,
6 glib,
7 gobject-introspection,
8 gtk3,
9 gtksourceview,
10 pango,
11 webkitgtk_4_1,
12 pygobject3,
13 pyyaml,
14 setuptools,
15}:
16
17buildPythonApplication rec {
18 pname = "rednotebook";
19 version = "2.39";
20 pyproject = true;
21
22 src = fetchFromGitHub {
23 owner = "jendrikseipp";
24 repo = "rednotebook";
25 tag = "v${version}";
26 sha256 = "sha256-H7Ub4dCJQa4Y3DNBzeIYWlNkpYftezY2MNWokw8ocoA=";
27 };
28
29 # We have not packaged tests.
30 doCheck = false;
31
32 nativeBuildInputs = [ gobject-introspection ];
33
34 build-system = [ setuptools ];
35
36 propagatedBuildInputs = [
37 gdk-pixbuf
38 glib
39 gtk3
40 gtksourceview
41 pango
42 webkitgtk_4_1
43 pygobject3
44 pyyaml
45 ];
46
47 makeWrapperArgs = [
48 "--set GI_TYPELIB_PATH $GI_TYPELIB_PATH"
49 "--prefix XDG_DATA_DIRS : $out/share"
50 "--suffix XDG_DATA_DIRS : $XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH"
51 ];
52
53 pythonImportsCheck = [ "rednotebook" ];
54
55 meta = with lib; {
56 homepage = "https://rednotebook.sourceforge.io/";
57 changelog = "https://github.com/jendrikseipp/rednotebook/blob/${src.tag}/CHANGELOG.md";
58 description = "Modern journal that includes a calendar navigation, customizable templates, export functionality and word clouds";
59 license = licenses.gpl2Plus;
60 maintainers = with maintainers; [ orivej ];
61 mainProgram = "rednotebook";
62 };
63}