From 02f9353c9051d2313221106a75f2ec89ee26f9c3 Mon Sep 17 00:00:00 2001 From: Michael White Date: Mon, 11 Jan 2021 16:27:38 -0700 Subject: [PATCH 1/3] clfswm: Add fresh CLFSWM built via lisp-packages, based on StumpWM --- .../quicklisp-to-nix-output/clfswm.nix | 25 +++++++++++++++++++ .../quicklisp-to-nix-overrides.nix | 10 ++++++++ .../lisp-modules/quicklisp-to-nix-systems.txt | 1 + .../lisp-modules/quicklisp-to-nix.nix | 7 ++++++ 4 files changed, 43 insertions(+) create mode 100644 pkgs/development/lisp-modules/quicklisp-to-nix-output/clfswm.nix diff --git a/pkgs/development/lisp-modules/quicklisp-to-nix-output/clfswm.nix b/pkgs/development/lisp-modules/quicklisp-to-nix-output/clfswm.nix new file mode 100644 index 00000000000..81b335520b0 --- /dev/null +++ b/pkgs/development/lisp-modules/quicklisp-to-nix-output/clfswm.nix @@ -0,0 +1,25 @@ +args @ { fetchurl, ... }: +rec { + baseName = ''clfswm''; + version = ''20161204-git''; + + description = ''CLFSWM: Fullscreen Window Manager''; + + deps = [ args."clx" ]; + + src = fetchurl { + url = ''http://beta.quicklisp.org/archive/clfswm/2016-12-04/clfswm-20161204-git.tgz''; + sha256 = ''1jgz127721dgcv3qm1knc335gy04vzh9gl0hshp256rxi82cpp73''; + }; + + packageName = "clfswm"; + + asdFilesToKeep = ["clfswm.asd"]; + overrides = x: x; +} +/* (SYSTEM clfswm DESCRIPTION CLFSWM: Fullscreen Window Manager SHA256 + 1jgz127721dgcv3qm1knc335gy04vzh9gl0hshp256rxi82cpp73 URL + http://beta.quicklisp.org/archive/clfswm/2016-12-04/clfswm-20161204-git.tgz + MD5 dc976785ef899837ab0fc50a4ed6b740 NAME clfswm FILENAME clfswm DEPS + ((NAME clx FILENAME clx)) DEPENDENCIES (clx) VERSION 20161204-git SIBLINGS + NIL PARASITES NIL) */ diff --git a/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix b/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix index 96d5867a3b3..b1fa379a1ed 100644 --- a/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix +++ b/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix @@ -231,4 +231,14 @@ $out/lib/common-lisp/query-fs" cl-cffi-gtk-gdk = addNativeLibs [pkgs.gtk3]; cl-cffi-gtk-gtk3 = addNativeLibs [pkgs.gtk3]; cl-webkit2 = addNativeLibs [pkgs.webkitgtk]; + clfswm = x: { + overrides = y: (x.overrides y) // { + postInstall = '' + export NIX_LISP_PRELAUNCH_HOOK="nix_lisp_build_system clfswm '(function clfswm:main)'" + "$out/bin/clfswm-lisp-launcher.sh" + + cp "$out/lib/common-lisp/clfswm/clfswm" "$out/bin" + ''; + }; + }; } diff --git a/pkgs/development/lisp-modules/quicklisp-to-nix-systems.txt b/pkgs/development/lisp-modules/quicklisp-to-nix-systems.txt index 52d626888a3..383510df777 100644 --- a/pkgs/development/lisp-modules/quicklisp-to-nix-systems.txt +++ b/pkgs/development/lisp-modules/quicklisp-to-nix-systems.txt @@ -82,6 +82,7 @@ cl-utilities cl-vectors cl-webkit2 cl-who +clfswm clx collectors command-line-arguments diff --git a/pkgs/development/lisp-modules/quicklisp-to-nix.nix b/pkgs/development/lisp-modules/quicklisp-to-nix.nix index 11244ec84a6..cbaa13af962 100644 --- a/pkgs/development/lisp-modules/quicklisp-to-nix.nix +++ b/pkgs/development/lisp-modules/quicklisp-to-nix.nix @@ -2848,6 +2848,13 @@ let quicklisp-to-nix-packages = rec { "fiasco" = quicklisp-to-nix-packages."fiasco"; })); + "clfswm" = buildLispPackage + ((f: x: (x // (f x))) + (qlOverrides."clfswm" or (x: {})) + (import ./quicklisp-to-nix-output/clfswm.nix { + inherit fetchurl; + "clx" = quicklisp-to-nix-packages."clx"; + })); "cl-who" = buildLispPackage ((f: x: (x // (f x))) From 952f2c76e00f49588238dffdd6055d88c6c15d0e Mon Sep 17 00:00:00 2001 From: Michael White Date: Mon, 11 Jan 2021 16:59:49 -0700 Subject: [PATCH 2/3] nixos/clfswm: Restore working quicklisp package --- nixos/modules/module-list.nix | 1 + nixos/modules/services/x11/window-managers/clfswm.nix | 4 ++-- nixos/modules/services/x11/window-managers/default.nix | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 84e7c10ff64..31d9e1f6eab 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -955,6 +955,7 @@ ./services/x11/urxvtd.nix ./services/x11/window-managers/awesome.nix ./services/x11/window-managers/default.nix + ./services/x11/window-managers/clfswm.nix ./services/x11/window-managers/fluxbox.nix ./services/x11/window-managers/icewm.nix ./services/x11/window-managers/bspwm.nix diff --git a/nixos/modules/services/x11/window-managers/clfswm.nix b/nixos/modules/services/x11/window-managers/clfswm.nix index 176c1f46127..171660c53ac 100644 --- a/nixos/modules/services/x11/window-managers/clfswm.nix +++ b/nixos/modules/services/x11/window-managers/clfswm.nix @@ -15,10 +15,10 @@ in services.xserver.windowManager.session = singleton { name = "clfswm"; start = '' - ${pkgs.clfswm}/bin/clfswm & + ${pkgs.lispPackages.clfswm}/bin/clfswm & waitPID=$! ''; }; - environment.systemPackages = [ pkgs.clfswm ]; + environment.systemPackages = [ pkgs.lispPackages.clfswm ]; }; } diff --git a/nixos/modules/services/x11/window-managers/default.nix b/nixos/modules/services/x11/window-managers/default.nix index 87702c58727..9ca24310e56 100644 --- a/nixos/modules/services/x11/window-managers/default.nix +++ b/nixos/modules/services/x11/window-managers/default.nix @@ -13,6 +13,7 @@ in ./berry.nix ./bspwm.nix ./cwm.nix + ./clfswm.nix ./dwm.nix ./evilwm.nix ./exwm.nix From d405d8972720750dc61befe96bc4c90a96ad774c Mon Sep 17 00:00:00 2001 From: Michael White Date: Mon, 11 Jan 2021 18:44:47 -0700 Subject: [PATCH 3/3] lisp-packages: Fix whitespace Replace a tab with spaces to fix a failing EditorConfig check. --- pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix b/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix index b1fa379a1ed..412fd4b8dee 100644 --- a/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix +++ b/pkgs/development/lisp-modules/quicklisp-to-nix-overrides.nix @@ -81,7 +81,7 @@ in postInstall = ((x.overrides y).postInstall or "") + '' export NIX_LISP_ASDF_PATHS="$NIX_LISP_ASDF_PATHS $out/lib/common-lisp/query-fs" - export HOME=$PWD + export HOME=$PWD export NIX_LISP_PRELAUNCH_HOOK="nix_lisp_build_system query-fs \ '(function query-fs:run-fs-with-cmdline-args)' '$linkedSystems'" "$out/bin/query-fs-lisp-launcher.sh"