Files
pvv-nixos-config/users/default.nix
h7x4 1b6ff9876d
All checks were successful
Build topology graph / evals (push) Successful in 3m54s
Eval nix flake / evals (push) Successful in 8m30s
Remove global packages from users, skrott: remove neovim properly
2026-01-26 13:16:06 +09:00

21 lines
633 B
Nix

{ lib, ... }:
with lib;
let
# get all files in folder
getDir = dir: builtins.readDir dir;
# find all files ending in ".nix" which are not this file, or directories, which may or may not contain a default.nix
files = dir: filterAttrs
(file: type: (type == "regular" && hasSuffix ".nix" file && file != "default.nix") || type == "directory")
(getDir dir);
# Turn the attrset into a list of the filenames
flatten = dir: mapAttrsToList (file: type: file) (files dir);
# Turn the filenames into absolute paths
makeAbsolute = dir: map (file: ./. + "/${file}") (flatten dir);
in
{
imports = makeAbsolute ./.;
}