blob: a64c76df0d2dcc71bab421e04ed9e3ddb25b675c (
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
|
{ lib
, buildDotnetModule
, fetchFromGitHub
, dotnetCorePackages
, gtk4
, libadwaita
, pkg-config
, wrapGAppsHook4
, glib
, shared-mime-info
, gdk-pixbuf
, blueprint-compiler
}:
buildDotnetModule rec {
pname = "denaro";
version = "2024.2.0";
src = fetchFromGitHub {
owner = "NickvisionApps";
repo = "Denaro";
rev = version;
hash = "sha256-fEhwup8SiYvKH2FtzruEFsj8axG5g3YJ917aqc8dn/8=";
};
dotnet-sdk = dotnetCorePackages.sdk_8_0;
dotnet-runtime = dotnetCorePackages.runtime_8_0;
projectFile = "NickvisionMoney.GNOME/NickvisionMoney.GNOME.csproj";
nugetDeps = ./deps.nix;
executables = "NickvisionMoney.GNOME";
nativeBuildInputs = [
pkg-config
wrapGAppsHook4
glib # For glib-compile-resources
shared-mime-info # For update-mime-database
gdk-pixbuf # Fixes icon missing in envs where GDK_PIXBUF_MODULE_FILE is not set
blueprint-compiler
];
buildInputs = [ gtk4 libadwaita ]; # Used by blueprint-compiler
# Denaro switches installation tool frequently (bash -> just -> cake)
# For maintainability, let's do it ourselves
postInstall = ''
substituteInPlace NickvisionMoney.Shared/Linux/org.nickvision.money.desktop.in --replace '@EXEC@' "NickvisionMoney.GNOME"
install -Dm444 NickvisionMoney.Shared/Resources/org.nickvision.money.svg -t $out/share/icons/hicolor/scalable/apps/
install -Dm444 NickvisionMoney.Shared/Resources/org.nickvision.money-symbolic.svg -t $out/share/icons/hicolor/symbolic/apps/
install -Dm444 NickvisionMoney.Shared/Linux/org.nickvision.money.desktop.in -T $out/share/applications/org.nickvision.money.desktop
'';
runtimeDeps = [
gtk4
libadwaita
glib # Fixes "Could not retrieve parent type - is the typeid valid?"
gdk-pixbuf
];
passthru.updateScript = ./update.sh;
meta = with lib; {
description = "Personal finance manager for GNOME";
homepage = "https://github.com/nlogozzo/NickvisionMoney";
mainProgram = "NickvisionMoney.GNOME";
license = licenses.mit;
changelog = "https://github.com/nlogozzo/NickvisionMoney/releases/tag/${version}";
maintainers = with maintainers; [ chuangzhu kashw2 ];
platforms = platforms.linux;
};
}
|