You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cross-platform git hooks for Octopus Deploy developer workflows.
3
+
Seamless, non-intrusive git hooks for worktree-heavy workflows.
4
+
5
+
Works out of the box — no changes to your existing `git worktree` commands. AI tools like Claude Code and Codex use normal git operations and benefit automatically. Supports macOS and Windows.
AI agents invoke git from subprocesses, which breaks the process ancestry detection. Add the following to your `CLAUDE.md` or `AGENTS.md` so the agent always passes the correct source worktree:
47
+
48
+
```
49
+
When creating git worktrees, always prefix the command with GIT_WORKTREE_SOURCE="$PWD":
50
+
51
+
GIT_WORKTREE_SOURCE="$PWD" git worktree add ../<branch> -b <branch> main
52
+
```
53
+
26
54
## Hooks
27
55
28
56
### `post-checkout`
29
57
30
-
Automatically copies local files from source worktree to newly created worktrees.
58
+
Automatically copies local files from the source worktree to a newly created worktree.
31
59
32
-
- Runs on `git worktree add`.
33
-
- Copies matching local files from source worktree to new worktree.
34
-
- Uses patterns from repo `.worktreeinclude` or fallback `~/.worktreeinclude`.
35
-
- Never overwrites existing files.
36
-
37
-
See `example.worktreeinclude` for pattern file examples.
60
+
- Triggers on `git worktree add`
61
+
- Detects the source worktree automatically (by process ancestry, then by most recently modified matching file, then falls back to main worktree)
62
+
- Never overwrites existing files in the destination
0 commit comments