From 3dc375cffbb4a8d09374e66002f5ee50be95ead2 Mon Sep 17 00:00:00 2001 From: sommerfeld Date: Tue, 19 May 2026 16:45:17 +0100 Subject: fix(remote-dev): symlink git pre-push hook with stripped chezmoi name MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `dot_config/git/hooks/executable_pre-push` only loses the `executable_` chezmoi attribute prefix during `chezmoi apply`. On remote-dev we use raw home-manager symlinks, so a directory symlink gave git a file literally named `executable_pre-push` — which is not a valid hook name and was silently ignored. Symlink each hook to its stripped target name (executable bit comes from the working-tree mode, which git follows through the symlink). --- remote-dev/home.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/remote-dev/home.nix b/remote-dev/home.nix index 35fccaf..926aadb 100644 --- a/remote-dev/home.nix +++ b/remote-dev/home.nix @@ -156,6 +156,11 @@ in "git/config".source = link "dot_config/git/config"; "git/attributes".source = link "dot_config/git/attributes"; "git/ignore".source = link "dot_config/git/ignore"; + # Git hooks: source filenames carry the chezmoi `executable_` attribute + # prefix which only chezmoi strips. On remote-dev we use raw symlinks, + # so map each hook to its stripped name explicitly. The executable bit + # comes from the working-tree file mode (git resolves the symlink). + "git/hooks/pre-push".source = link "dot_config/git/hooks/executable_pre-push"; }; # ── Rootless podman config ────────────────────────────────────────────────── -- cgit v1.3.1