From 2f21379b8c8ba62e71c7e0a448b7c21b3bc1fa05 Mon Sep 17 00:00:00 2001 From: seth Date: Sun, 7 Jul 2024 15:19:35 -0400 Subject: [PATCH] flake/devshell: make `devshell` optional as this isn't used by consumers, they should be able to remove this input via `inputs.nixvim.inputs.devshell.follows = ""` --- flake-modules/dev/devshell.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/flake-modules/dev/devshell.nix b/flake-modules/dev/devshell.nix index 40794509..d1ef469c 100644 --- a/flake-modules/dev/devshell.nix +++ b/flake-modules/dev/devshell.nix @@ -1,15 +1,16 @@ -{ inputs, ... }: +{ lib, inputs, ... }: { - imports = [ inputs.devshell.flakeModule ]; + imports = lib.optional (inputs.devshell ? flakeModule) inputs.devshell.flakeModule; perSystem = { + lib, pkgs, config, system, ... }: - { + lib.optionalAttrs (inputs.devshell ? flakeModule) { devshells.default = { devshell.startup.pre-commit.text = config.pre-commit.installationScript;