From 5a107254d245dae010c21d44b6490485c3bf3093 Mon Sep 17 00:00:00 2001 From: Andrea Ciceri Date: Wed, 16 Apr 2025 12:39:16 +0200 Subject: [PATCH] Use upstream cura-appimage --- hmModules/cura/default.nix | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/hmModules/cura/default.nix b/hmModules/cura/default.nix index 96a2f2c..a4999b8 100644 --- a/hmModules/cura/default.nix +++ b/hmModules/cura/default.nix @@ -1,31 +1,6 @@ { pkgs, ... }: { home.packages = [ - ( - let - cura5 = pkgs.appimageTools.wrapType2 rec { - pname = "cura5"; - version = "5.8.0"; - src = pkgs.fetchurl { - url = "https://github.com/Ultimaker/Cura/releases/download/${version}/UltiMaker-Cura-${version}-linux-X64.AppImage"; - hash = "sha256-EojVAe+o43W80ES5BY3QgGRTxztwS+B6kIOfJOtULOg="; - }; - }; - in - pkgs.writeScriptBin "cura" '' - #! ${pkgs.bash}/bin/bash - # AppImage version of Cura loses current working directory and treats all paths relateive to $HOME. - # So we convert each of the files passed as argument to an absolute path. - # This fixes use cases like `cd /path/to/my/files; cura mymodel.stl anothermodel.stl`. - args=() - for a in "$@"; do - if [ -e "$a" ]; then - a="$(realpath "$a")" - fi - args+=("$a") - done - QT_QPA_PLATFORM=xcb exec "${cura5}/bin/cura5" "''${args[@]}" - '' - ) + pkgs.cura-appimage ]; }