mirror of
https://github.com/nix-community/flakelight.git
synced 2025-02-18 02:10:51 +01:00
Skip default.nix in loadNixDir
This will allow a default.nix to use loadNixDir to load its directory.
This commit is contained in:
parent
426480067c
commit
ec3ce2b4aa
@ -281,12 +281,13 @@ let
|
|||||||
loadNixDir = path: genAttrs
|
loadNixDir = path: genAttrs
|
||||||
(pipe (readDir path) [
|
(pipe (readDir path) [
|
||||||
attrNames
|
attrNames
|
||||||
|
(filter (s: s != "default.nix"))
|
||||||
(filter (hasSuffix ".nix"))
|
(filter (hasSuffix ".nix"))
|
||||||
(map (removeSuffix ".nix"))
|
(map (removeSuffix ".nix"))
|
||||||
(map (removePrefix "+"))
|
(map (removePrefix "+"))
|
||||||
])
|
])
|
||||||
(p: import (path +
|
(p: import (path + (if pathExists
|
||||||
(if pathExists (path + "/${p}.nix") then "/${p}.nix" else "/+${p}.nix")));
|
(path + "/+${p}.nix") then "/+${p}.nix" else "/${p}.nix")));
|
||||||
|
|
||||||
systems = rec {
|
systems = rec {
|
||||||
linuxDefault = [
|
linuxDefault = [
|
||||||
|
Loading…
Reference in New Issue
Block a user