472aeafc57
GitOrigin-RevId: c31898adf5a8ed202ce5bea9f347b1c6871f32d1
56 lines
1.4 KiB
Nix
56 lines
1.4 KiB
Nix
{
|
|
lib,
|
|
stdenvNoCC,
|
|
fetchurl,
|
|
dpkg,
|
|
makeWrapper,
|
|
electron,
|
|
}:
|
|
stdenvNoCC.mkDerivation (finalAttrs: {
|
|
pname = "proton-pass";
|
|
version = "1.23.0";
|
|
|
|
src = fetchurl {
|
|
url = "https://proton.me/download/pass/linux/x64/proton-pass_${finalAttrs.version}_amd64.deb";
|
|
hash = "sha256-ewrPk3v1jgF87uY+7P8oQdWARcuFKdfiM1BzulMPBpg=";
|
|
};
|
|
|
|
dontConfigure = true;
|
|
dontBuild = true;
|
|
|
|
nativeBuildInputs = [
|
|
dpkg
|
|
makeWrapper
|
|
];
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
mkdir -p $out
|
|
cp -r usr/share/ $out/
|
|
cp -r usr/lib/proton-pass/resources/app.asar $out/share/
|
|
runHook postInstall
|
|
'';
|
|
|
|
preFixup = ''
|
|
makeWrapper ${lib.getExe electron} $out/bin/proton-pass \
|
|
--add-flags $out/share/app.asar \
|
|
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
|
|
--set-default ELECTRON_FORCE_IS_PACKAGED 1 \
|
|
--set-default ELECTRON_IS_DEV 0 \
|
|
--inherit-argv0
|
|
'';
|
|
|
|
meta = {
|
|
description = "Desktop application for Proton Pass";
|
|
homepage = "https://proton.me/pass";
|
|
license = lib.licenses.gpl3Plus;
|
|
maintainers = with lib.maintainers; [
|
|
luftmensch-luftmensch
|
|
massimogengarelli
|
|
sebtm
|
|
];
|
|
platforms = [ "x86_64-linux" ];
|
|
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
|
|
mainProgram = "proton-pass";
|
|
};
|
|
})
|