element-desktop: add commandLineArgs (#345453)

This commit is contained in:
Friedrich Altheide 2024-10-11 10:13:04 +02:00 committed by GitHub
parent 0801558a65
commit 04e3c70d0e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -17,6 +17,8 @@
, CoreServices
, desktopToDarwinBundle
, useKeytar ? true
# command line arguments which are always set
, commandLineArgs ? ""
}:
let
@ -106,7 +108,8 @@ stdenv.mkDerivation (finalAttrs: builtins.removeAttrs pinData [ "hashes" ] // {
makeWrapper '${electron}/bin/electron' "$out/bin/${executableName}" \
--set LD_PRELOAD ${sqlcipher}/lib/libsqlcipher.so \
--add-flags "$out/share/element/electron" \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
--add-flags ${lib.escapeShellArg commandLineArgs}
runHook postInstall
'';