depot/third_party/nixpkgs/pkgs/applications/misc/protonup-qt/default.nix
Default email 4d5a95770c Project import generated by Copybara.
GitOrigin-RevId: 3c5319ad3aa51551182ac82ea17ab1c6b0f0df89
2023-03-04 15:14:45 +03:00

33 lines
1.3 KiB
Nix

{ appimageTools, fetchurl, lib }:
let
pname = "protonup-qt";
version = "2.7.7";
src = fetchurl {
url = "https://github.com/DavidoTek/ProtonUp-Qt/releases/download/v${version}/ProtonUp-Qt-${version}-x86_64.AppImage";
sha256 = "sha256-eDi13DYS4Rtj3ouuhRoET1Ctc4D7p50khqXNOSBIvto=";
};
appimageContents = appimageTools.extractType2 { inherit pname version src; };
in
appimageTools.wrapType2 rec {
inherit pname version src;
extraInstallCommands = ''
mv $out/bin/{${pname}-${version},${pname}}
mkdir -p $out/share/{applications,pixmaps}
cp ${appimageContents}/net.davidotek.pupgui2.desktop $out/share/applications/${pname}.desktop
cp ${appimageContents}/net.davidotek.pupgui2.png $out/share/pixmaps/${pname}.png
substituteInPlace $out/share/applications/${pname}.desktop \
--replace 'Exec=net.davidotek.pupgui2' 'Exec=${pname}' \
--replace 'Icon=net.davidotek.pupgui2' 'Icon=${pname}'
'';
meta = with lib; {
homepage = "https://davidotek.github.io/protonup-qt/";
description = "Install and manage Proton-GE and Luxtorpeda for Steam and Wine-GE for Lutris with this graphical user interface.";
license = licenses.gpl3;
sourceProvenance = with sourceTypes; [ binaryNativeCode ];
mainProgram = "protonup-qt";
platforms = [ "x86_64-linux" ];
maintainers = with maintainers; [ michaelBelsanti ];
};
}