Skip to content

Track moving git-hooks worktree logic into prek #2511

@schickling

Description

@schickling

Problem

The current devenv git-hooks integration has accumulated substantial Git config orchestration logic to work around worktree-specific hook installation behavior. This is hard to maintain in devenv and duplicates installer concerns that should live upstream in prek.

Context

Decision

Implement the worktree-safe and transactional installation semantics in prek first, then simplify devenv to a thin integration wrapper.

Follow-up plan in devenv

  1. Start a fresh devenv branch/PR after prek fix lands (or is available in nixpkgs input).
  2. Remove most bash-level Git config mutation logic from src/modules/integrations/git-hooks.nix.
  3. Keep only stage mapping / invocation glue needed for devenv task wiring.
  4. Add regression coverage in devenv integration tests for the previously reported worktree scenario.
  5. Verify no behavior regressions for non-worktree repositories.

Acceptance criteria


Created on behalf of @schickling.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions