about summary refs log tree commit diff
path: root/pkgs/tools/X11/sx/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/tools/X11/sx/default.nix')
-rw-r--r--pkgs/tools/X11/sx/default.nix33
1 files changed, 24 insertions, 9 deletions
diff --git a/pkgs/tools/X11/sx/default.nix b/pkgs/tools/X11/sx/default.nix
index c03d4443fcf0e..1b04bb8876d33 100644
--- a/pkgs/tools/X11/sx/default.nix
+++ b/pkgs/tools/X11/sx/default.nix
@@ -1,6 +1,13 @@
-{ coreutils, fetchFromGitHub, lib, makeWrapper, stdenv, util-linux, xauth, xorgserver }:
+{ lib
+, bash
+, coreutils
+, fetchFromGitHub
+, resholve
+, xauth
+, xorgserver
+}:
 
-stdenv.mkDerivation rec {
+resholve.mkDerivation rec {
   pname = "sx";
   version = "2.1.7";
 
@@ -11,20 +18,28 @@ stdenv.mkDerivation rec {
     sha256 = "0xv15m30nhcknasqiybj5wwf7l91q4a4jf6xind8x5x00c6br6nl";
   };
 
-  nativeBuildInputs = [ makeWrapper ];
-
   makeFlags = [ "PREFIX=$(out)" ];
 
-  postInstall = ''
-    wrapProgram $out/bin/sx \
-      --prefix PATH : ${lib.makeBinPath [ coreutils util-linux xorgserver xauth ]}
-  '';
+  solutions = {
+    sx = {
+      scripts = [ "bin/sx" ];
+      interpreter = "${bash}/bin/sh";
+      inputs = [
+        coreutils
+        xauth
+        xorgserver
+      ];
+      execer = [
+        "cannot:${xorgserver}/bin/Xorg"
+      ];
+    };
+  };
 
   meta = with lib; {
     description = "Simple alternative to both xinit and startx for starting a Xorg server";
     homepage = "https://github.com/earnestly/sx";
     license = licenses.mit;
     platforms = platforms.linux;
-    maintainers = with maintainers; [ figsoda ];
+    maintainers = with maintainers; [ figsoda thiagokokada ];
   };
 }