mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-03-22 22:29:06 +01:00
scripts: Move nebula scripts into subdirectory
This commit is contained in:
parent
b94ff46b24
commit
0f69eb0355
3 changed files with 11 additions and 4 deletions
|
|
@ -10,9 +10,16 @@
|
||||||
{
|
{
|
||||||
packages =
|
packages =
|
||||||
"${self}/scripts"
|
"${self}/scripts"
|
||||||
|> builtins.readDir
|
|> lib.filesystem.listFilesRecursive
|
||||||
|> lib.attrNames
|
|> lib.map (file: {
|
||||||
|> lib.map (name: name |> lib.removeSuffix ".nix")
|
name =
|
||||||
|> self.lib.genAttrs (name: import "${self}/scripts/${name}.nix" { inherit self' pkgs lib; });
|
file
|
||||||
|
|> lib.unsafeDiscardStringContext
|
||||||
|
|> lib.removePrefix "${self}/scripts/"
|
||||||
|
|> lib.removeSuffix ".nix"
|
||||||
|
|> lib.replaceString "/" "-";
|
||||||
|
value = import file { inherit self' pkgs lib; };
|
||||||
|
})
|
||||||
|
|> lib.listToAttrs;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue