Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The appimage application does not open in NixOS #47

Open
Inarizxc opened this issue Dec 3, 2024 · 3 comments
Open

The appimage application does not open in NixOS #47

Inarizxc opened this issue Dec 3, 2024 · 3 comments

Comments

@Inarizxc
Copy link

Inarizxc commented Dec 3, 2024

The terminal outputs:

** (ModrinthApp:86703): WARNING **: 18:09:39.342: atk-bridge: get_device_events_reply: unknown signature

It started the first time and then stopped.

@Inarizxc
Copy link
Author

Inarizxc commented Dec 3, 2024

Here's my file for creating the derivation:

{appimageTools, fetchurl, ...}:
let
  pname = "ModrinthApp";
  version = "0.8.9";

  src = fetchurl {
    url = "https://github.com/DIDIRUS4/AstralRinth/releases/download/ARF-v${version}/AstralRinth.App_${version}_amd64.AppImage";
    sha256 = "sha256-HYb3kYfYjRTqHv4zVw5xWXELyVC2ATivf2ebvvKadx8=";
  };

  appimageContents = appimageTools.extractType2 {
    inherit pname version src;
  };
in
appimageTools.wrapType2 rec {
  inherit pname version src;

  extraInstallCommands = ''
    mkdir -p $out/share/applications $out/share/pixmaps
    # cp ${appimageContents}/AstralRinth\ App.desktop $out/share/applications/
    cp ${appimageContents}/AstralRinth\ App.png $out/share/pixmaps/

    touch $out/share/applications/AstralRinth\ App.desktop

    cat > $out/share/applications/AstralRinth\ App.desktop <<EOF
    [Desktop Entry]
    Categories=Game;
    Exec=nvidia-offload ModrinthApp
    Icon=ModrinthApp
    Name=AstralRinth App
    Terminal=false
    Type=Application
    MimeType=application/zip+mrpack;x-scheme-handler/modrinth

    # for n in {16,32,48,64,128}; do
    #   size=$n"x"$n
    #   mkdir -p $out/share/icons/hicolor/$size/apps
    #   file="default"$n".png"
    #   cp -r ${appimageContents}/usr/share/* $out/share/
    # done

    # substituteInPlace $out/share/applications/NeoHtop.desktop \
    #   --replace-fail "Exec=neohtop %u" "Exec=$out/bin/${pname} %u"
  '';
}

@Inarizxc
Copy link
Author

Inarizxc commented Dec 3, 2024

The application starts if you delete the app directory

@Inarizxc
Copy link
Author

Inarizxc commented Dec 3, 2024

Apparently everything stops working after enabling native decorations, restarting to apply the customization, and another restart

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant