mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 07:53:19 +00:00
haskell.lib.packagesFromDirectory: only .nix
files
This changes `haskell.lib.packagesFromDirectory` to ignore non-Nix files so that it doesn't attempt to run `callPackage` on, say, a `.md` file in the same directory.
This commit is contained in:
parent
5cd7971391
commit
aa75fa1eaa
@ -407,7 +407,9 @@ rec {
|
||||
|
||||
self: super:
|
||||
let
|
||||
haskellPaths = builtins.attrNames (builtins.readDir directory);
|
||||
haskellPaths =
|
||||
lib.filter (lib.hasSuffix ".nix")
|
||||
(builtins.attrNames (builtins.readDir directory));
|
||||
|
||||
toKeyVal = file: {
|
||||
name = builtins.replaceStrings [ ".nix" ] [ "" ] file;
|
||||
|
Loading…
Reference in New Issue
Block a user