about summary refs log tree commit diff
path: root/pkgs/tools/X11
diff options
context:
space:
mode:
authorSandro <sandro.jaeckel@gmail.com>2021-07-13 22:52:31 +0200
committerGitHub <noreply@github.com>2021-07-13 22:52:31 +0200
commit70fca137996ff4677d89879aed5310b13b0fcac9 (patch)
treec2daf4d2bc32018a1db84b2cdea9e2c3683e5ecb /pkgs/tools/X11
parentdac74fead8737d6bf0823f22da26c7344f69bc0a (diff)
parent6c3c1e46a2a90c891920c9487598770a24d71922 (diff)
Merge pull request #129816 from figsoda/sx
Diffstat (limited to 'pkgs/tools/X11')
-rw-r--r--pkgs/tools/X11/sx/default.nix30
1 files changed, 30 insertions, 0 deletions
diff --git a/pkgs/tools/X11/sx/default.nix b/pkgs/tools/X11/sx/default.nix
new file mode 100644
index 0000000000000..c03d4443fcf0e
--- /dev/null
+++ b/pkgs/tools/X11/sx/default.nix
@@ -0,0 +1,30 @@
+{ coreutils, fetchFromGitHub, lib, makeWrapper, stdenv, util-linux, xauth, xorgserver }:
+
+stdenv.mkDerivation rec {
+  pname = "sx";
+  version = "2.1.7";
+
+  src = fetchFromGitHub {
+    owner = "earnestly";
+    repo = pname;
+    rev = version;
+    sha256 = "0xv15m30nhcknasqiybj5wwf7l91q4a4jf6xind8x5x00c6br6nl";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  postInstall = ''
+    wrapProgram $out/bin/sx \
+      --prefix PATH : ${lib.makeBinPath [ coreutils util-linux xorgserver xauth ]}
+  '';
+
+  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 ];
+  };
+}