diff options
author | ene <ene@sils.li> | 2023-02-02 19:14:05 +0100 |
---|---|---|
committer | ene <ene@sils.li> | 2023-02-03 17:41:34 +0100 |
commit | 1712001d2c6c8b5aeb83972663fd05b4763d38ab (patch) | |
tree | a90cc8332df16df00edf84c0d051f2a4606f97b9 /system | |
parent | Feat: Reworked the packages configuration (diff) | |
download | nixos-config-1712001d2c6c8b5aeb83972663fd05b4763d38ab.tar.gz nixos-config-1712001d2c6c8b5aeb83972663fd05b4763d38ab.zip |
Fix(packages): Add a function to disassemble the set
Diffstat (limited to '')
-rw-r--r-- | system/packages/packages.nix | 60 |
1 files changed, 30 insertions, 30 deletions
diff --git a/system/packages/packages.nix b/system/packages/packages.nix index e427ac94..a0b47bf1 100644 --- a/system/packages/packages.nix +++ b/system/packages/packages.nix @@ -1,8 +1,4 @@ -{ - config, - pkgs, - ... -}: +{pkgs, ...}: with pkgs; let Gui = { Terminals = [ @@ -69,7 +65,7 @@ with pkgs; let ]; WM = { - inherit river; # A dynamic tiling wayland compositor + river = [river]; # A dynamic tiling wayland compositor CLITools = [ lswt # List Wayland toplevels @@ -100,7 +96,7 @@ with pkgs; let }; LF = { - inherit lf; # A terminal file manager inspired by ranger + lf = [lf]; # A terminal file manager inspired by ranger Functions = [ broot # Fuzzy Search + tree + cd @@ -167,8 +163,8 @@ with pkgs; let }; Zsh = [ - zsh # A very advanced and programmable command interpreter (shell) for UNIX - zsh-syntax-highlighting # Fish shell like syntax highlighting for Zsh + #zsh # A very advanced and programmable command interpreter (shell) for UNIX + #zsh-syntax-highlighting # Fish shell like syntax highlighting for Zsh # next one only works if your alias is only a command, e.g. if you `alias='cat some_file.txt &2> /dev/null'`, running `cat some_file.txt` won't trigger it. # TODO find something better for this use case @@ -261,27 +257,32 @@ with pkgs; let #xorg-bdftopcf # Convert X font from Bitmap Distribution Format to Portable Compiled Format mapFun = x: - if isAttrs x - then attrValues x - else x; + if builtins.isAttrs x + then + if lib.isDerivation x + then [x] + else builtins.attrValues x + else [x]; in { - environment.systemPackages = with builtins; [ - map - mapFun - (map - mapFun - (map - mapFun - (attrValues Gui))) - - map - mapFun - (map - mapFun - (map - mapFun - (attrValues TuiCli))) - ]; + environment.systemPackages = with builtins; + concatLists + (concatLists [ + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (attrValues Gui))))))) + + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (concatMap mapFun + (attrValues TuiCli))))))) + ]); } # QEMU # TEX @@ -359,4 +360,3 @@ in { #xorg-xwininfo # Command-line utility to print information about windows on an X server #xorg-xwud # X Window System image undumping utility # }}} - |