From 4726277afa9ed2514735f8c9ac9f3de0294d9edd Mon Sep 17 00:00:00 2001 From: Sander Date: Sat, 23 Nov 2024 04:15:50 +0400 Subject: [PATCH] git-hooks: update task order setup --- src/modules/integrations/git-hooks.nix | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/modules/integrations/git-hooks.nix b/src/modules/integrations/git-hooks.nix index ab9a7a41f..ed974afc0 100644 --- a/src/modules/integrations/git-hooks.nix +++ b/src/modules/integrations/git-hooks.nix @@ -34,10 +34,14 @@ in packages = lib.mkAfter ([ config.git-hooks.package ] ++ (config.git-hooks.enabledPackages or [ ])); tasks = { # TODO: split installation script into status + exec - "devenv:git-hooks:install".exec = config.git-hooks.installationScript; - "devenv:git-hooks:run".exec = "pre-commit run -a"; - "devenv:enterShell".after = [ "devenv:git-hooks:install" ]; - "devenv:enterTest".after = [ "devenv:git-hooks:run" ]; + "devenv:git-hooks:install" = { + exec = config.git-hooks.installationScript; + before = [ "devenv:enterShell" ]; + }; + "devenv:git-hooks:run" = { + exec = "pre-commit run -a"; + before = [ "devenv:enterShell" ]; + }; }; }; }