summary refs log tree commit diff
path: root/pkgs/tools
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/tools')
-rw-r--r--pkgs/tools/misc/pandoc-drawio-filter/default.nix23
1 files changed, 2 insertions, 21 deletions
diff --git a/pkgs/tools/misc/pandoc-drawio-filter/default.nix b/pkgs/tools/misc/pandoc-drawio-filter/default.nix
index 1279296143c..73dd658dfb1 100644
--- a/pkgs/tools/misc/pandoc-drawio-filter/default.nix
+++ b/pkgs/tools/misc/pandoc-drawio-filter/default.nix
@@ -1,5 +1,5 @@
 { buildPythonApplication
-, drawio
+, drawio-headless
 , fetchFromGitHub
 , lib
 , pandoc
@@ -21,32 +21,13 @@ let
     sha256 = "sha256-2XJSAfxqEmmamWIAM3vZqi0mZjUUugmR3zWw8Imjadk=";
   };
 
-  wrappedDrawio = writeScriptBin "drawio" ''
-    #!${runtimeShell}
-
-    # Electron really wants a configuration directory to not die with:
-    # "Error: Failed to get 'appData' path"
-    # so we give it some temp dir as XDG_CONFIG_HOME
-    tmpdir=$(mktemp -d)
-
-    function cleanup {
-      rm -rf "$tmpdir"
-    }
-    trap cleanup EXIT
-
-    # Drawio needs to run in a virtual X session, because Electron
-    # refuses to work and dies with an unhelpful error message otherwise:
-    # "The futex facility returned an unexpected error code."
-    XDG_CONFIG_HOME="$tmpdir" ${xvfb-run}/bin/xvfb-run ${drawio}/bin/drawio $@
-  '';
-
   pandoc-drawio-filter = buildPythonApplication {
     pname = "pandoc-drawio-filter";
 
     inherit src version;
 
     propagatedBuildInputs = [
-      wrappedDrawio
+      drawio-headless
       pandocfilters
     ];