Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions modules/hook.nix
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ in

package = mkOption {
type = types.nullOr types.package;
default = null;
description = lib.mdDoc
''
An optional package that provides the hook.
Expand Down
2 changes: 1 addition & 1 deletion modules/pre-commit.nix
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ in
Useful for including into the developer environment.
'';

default = builtins.map (hook: hook.package) (lib.filter (hook: hook.enable) (builtins.attrValues config.hooks));
default = builtins.map (hook: hook.package) (lib.filter (hook: hook.enable && hook.package != null) (builtins.attrValues config.hooks));
};

hooks =
Expand Down