From 1a86b0fc0f25b6e0ce1d554111eed14e581e4b1c Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Mon, 18 Oct 2021 01:03:56 +0200 Subject: [PATCH] fix(cli): deploy git hooks to correct directory 'doom install' now consults git to find the hooks directory, which will work for users who have Doom as a submodule (#5632). Fix #5632 --- core/cli/ci.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/cli/ci.el b/core/cli/ci.el index f1150945b..78fe54e94 100644 --- a/core/cli/ci.el +++ b/core/cli/ci.el @@ -14,8 +14,8 @@ (defun doom-cli--ci-deploy-hooks (&optional noforce) - (let ((dir (doom-path doom-emacs-dir ".git/hooks")) - (default-directory doom-emacs-dir)) + (let* ((default-directory doom-emacs-dir) + (dir (cdr (doom-call-process "git" "rev-parse" "--git-path" "hooks")))) (make-directory dir 'parents) (dolist (hook '("commit-msg" "pre-push")) (let ((file (doom-path dir hook)))