Skip to content

Commit 5477098

Browse files
authored
Merge pull request NixOS#331572 from onny/quba
quba: init at 1.4.0
2 parents 84eede1 + 368f21f commit 5477098

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed

pkgs/by-name/qu/quba/package.nix

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
lib,
3+
appimageTools,
4+
fetchurl,
5+
}:
6+
7+
let
8+
version = "1.4.0";
9+
pname = "quba";
10+
name = "${pname}-${version}";
11+
12+
src = fetchurl {
13+
url = "https://github.com/ZUGFeRD/quba-viewer/releases/download/v${version}/Quba-${version}.AppImage";
14+
hash = "sha256-EsTF7W1np5qbQQh3pdqsFe32olvGK3AowGWjqHPEfoM=";
15+
};
16+
17+
appimageContents = appimageTools.extractType1 { inherit name src; };
18+
in
19+
appimageTools.wrapType1 {
20+
inherit name src;
21+
22+
extraInstallCommands = ''
23+
mv $out/bin/${name} $out/bin/${pname}
24+
install -m 444 -D ${appimageContents}/${pname}.desktop -t $out/share/applications
25+
substituteInPlace $out/share/applications/${pname}.desktop \
26+
--replace-fail 'Exec=AppRun' 'Exec=${pname}'
27+
cp -r ${appimageContents}/usr/share/icons $out/share
28+
'';
29+
30+
meta = {
31+
description = "Viewer for electronic invoices";
32+
homepage = "https://github.com/ZUGFeRD/quba-viewer";
33+
downloadPage = "https://github.com/ZUGFeRD/quba-viewer/releases";
34+
license = lib.licenses.asl20;
35+
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
36+
maintainers = with lib.maintainers; [ onny ];
37+
platforms = [ "x86_64-linux" ];
38+
};
39+
}

0 commit comments

Comments
 (0)