Merge pull request #226102 from Enzime/joplin-desktop-wayland

This commit is contained in:
Artturi 2023-04-14 07:58:09 +03:00 committed by GitHub
commit 6464ec1b87
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,4 @@
{ lib, stdenv, appimageTools, fetchurl, undmg }:
{ lib, stdenv, appimageTools, fetchurl, makeWrapper, undmg }:
let
pname = "joplin-desktop";
@ -51,6 +51,9 @@ let
extraPkgs = appimageTools.defaultFhsEnvArgs.multiPkgs;
extraInstallCommands = ''
mv $out/bin/{${name},${pname}}
source "${makeWrapper}/nix-support/setup-hook"
wrapProgram $out/bin/${pname} \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland}}"
install -Dm444 ${appimageContents}/@joplinapp-desktop.desktop -t $out/share/applications
install -Dm444 ${appimageContents}/@joplinapp-desktop.png -t $out/share/pixmaps
substituteInPlace $out/share/applications/@joplinapp-desktop.desktop \