diff options
author | William Casarin | 2015-03-15 20:24:54 -0700 |
---|---|---|
committer | William Casarin | 2015-03-21 11:02:44 -0700 |
commit | ea2baa8abfc44ae3b32ec424cd81d035225ae100 (patch) | |
tree | 60de60d5d3f69596403153c23970dee26761ab36 | |
parent | 045164638217b8ce2492019db38fdeb4a508d6a3 (diff) |
spectrwm window manager
-rw-r--r-- | lib/maintainers.nix | 1 | ||||
-rw-r--r-- | nixos/modules/services/x11/window-managers/default.nix | 1 | ||||
-rw-r--r-- | nixos/modules/services/x11/window-managers/spectrwm.nix | 33 | ||||
-rw-r--r-- | pkgs/applications/window-managers/spectrwm/default.nix | 59 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 2 |
5 files changed, 96 insertions, 0 deletions
diff --git a/lib/maintainers.nix b/lib/maintainers.nix index 194aaec5c251..358cbda44e47 100644 --- a/lib/maintainers.nix +++ b/lib/maintainers.nix @@ -95,6 +95,7 @@ iyzsong = "Song Wenwu <iyzsong@gmail.com>"; j-keck = "Jürgen Keck <jhyphenkeck@gmail.com>"; jagajaga = "Arseniy Seroka <ars.seroka@gmail.com>"; + jb55 = "William Casarin <bill@casarin.me>"; jcumming = "Jack Cummings <jack@mudshark.org>"; jgeerds = "Jascha Geerds <jg@ekby.de>"; jirkamarsik = "Jirka Marsik <jiri.marsik89@gmail.com>"; diff --git a/nixos/modules/services/x11/window-managers/default.nix b/nixos/modules/services/x11/window-managers/default.nix index 97cc198137c4..1912b8aa5a91 100644 --- a/nixos/modules/services/x11/window-managers/default.nix +++ b/nixos/modules/services/x11/window-managers/default.nix @@ -18,6 +18,7 @@ in ./openbox.nix ./sawfish.nix ./stumpwm.nix + ./spectrwm.nix ./twm.nix ./windowmaker.nix ./wmii.nix diff --git a/nixos/modules/services/x11/window-managers/spectrwm.nix b/nixos/modules/services/x11/window-managers/spectrwm.nix new file mode 100644 index 000000000000..5db6b41ba8fd --- /dev/null +++ b/nixos/modules/services/x11/window-managers/spectrwm.nix @@ -0,0 +1,33 @@ + +{ config, lib, pkgs, ... }: + +with lib; + +let + cfg = config.services.xserver.windowManager.spectrwm; +in + +{ + options = { + services.xserver.windowManager.spectrwm = { + enable = mkOption { + default = false; + example = true; + description = "Enable the spectrwm window manager."; + }; + }; + }; + + config = mkIf cfg.enable { + services.xserver.windowManager = { + session = [{ + name = "spectrwm"; + start = '' + ${pkgs.spectrwm}/bin/spectrwm & + waitPID=$! + ''; + }]; + }; + environment.systemPackages = [ pkgs.spectrwm ]; + }; +} diff --git a/pkgs/applications/window-managers/spectrwm/default.nix b/pkgs/applications/window-managers/spectrwm/default.nix new file mode 100644 index 000000000000..ad6fcddf5be4 --- /dev/null +++ b/pkgs/applications/window-managers/spectrwm/default.nix @@ -0,0 +1,59 @@ +{ fetchurl +, coreutils +, libX11 +, libXrandr +, libXcursor +, libXft +, libXt +, libxcb +, xcbutil +, xcb-util-cursor +, xcbutilkeysyms +, xcbutilwm +, stdenv +}: + +stdenv.mkDerivation rec { + name = "spectrwm-${version}"; + version = "2.6.2"; + + src = fetchurl { + url = "https://github.com/conformal/spectrwm/archive/SPECTRWM_2_6_2.tar.gz"; + sha256 = "1pc9p3vwa4bsv76myqkqhp4cxspr72s5igi7cs9xrpd4xx6xc90s"; + }; + + buildInputs = [ + libX11 + libxcb + libXrandr + libXcursor + libXft + libXt + xcbutil + xcb-util-cursor + xcbutilkeysyms + xcbutilwm + ]; + + sourceRoot = "spectrwm-SPECTRWM_2_6_2/linux"; + makeFlags="PREFIX=$(out)"; + installPhase = "PREFIX=$out make install"; + + meta = with stdenv.lib; { + description = "A tiling window manager"; + homepage = "https://github.com/conformal/spectrwm"; + maintainers = with maintainers; [ jb55 ]; + license = licenses.isc; + platforms = platforms.all; + + longDescription = '' + spectrwm is a small dynamic tiling window manager for X11. It + tries to stay out of the way so that valuable screen real estate + can be used for much more important stuff. It has sane defaults + and does not require one to learn a language to do any + configuration. It was written by hackers for hackers and it + strives to be small, compact and fast. + ''; + }; + +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 41c172476c07..8d1b684b673e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -10732,6 +10732,8 @@ let hydrogen = callPackage ../applications/audio/hydrogen { }; + spectrwm = callPackage ../applications/window-managers/spectrwm { }; + i3 = callPackage ../applications/window-managers/i3 { xcb-util-cursor = if stdenv.isDarwin then xcb-util-cursor-HEAD else xcb-util-cursor; }; |