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
Copy file name to clipboardExpand all lines: src/docs/Ways-of-Working/Git-Worktrees.md
+20-5Lines changed: 20 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,22 +9,22 @@ All repositories are set up as **bare clones with worktrees**. This enables para
9
9
| Only one branch checked out at a time | Each issue gets its own worktree — parallel by default |
10
10
| Switching branches requires clean state | Worktrees are independent — no stashing or committing WIP |
11
11
| Agent work blocks human work on same repo | Different worktrees, no interference |
12
-
| Default branch gets dirty during development |`main/` worktree is always a clean reference|
12
+
| Default branch gets dirty during development |`<default>/` worktree is always a clean reference |
13
13
14
14
## Repository layout
15
15
16
16
```text
17
17
<repo-root>/
18
18
├── .bare/ # bare git data (the actual repository)
19
19
├── .git # file containing: gitdir: ./.bare
20
-
├── main/ # worktree: default branch (always clean, never worked in directly)
20
+
├── <default>/ # worktree: default branch (always clean, never worked in directly)
21
21
├── 42-add-pagination/ # worktree: issue #42 in progress
22
22
└── 99-fix-null-ref/ # worktree: issue #99 in progress
23
23
```
24
24
25
25
-**`.bare/`** — the shared git object store. All worktrees share this.
26
26
-**`.git`** — a file (not a directory) that points git tooling to `.bare/`.
27
-
-**`main/`** — the default branch worktree. Kept as a clean reference. Used for diffing, reading docs, running comparisons. Never directly committed to.
27
+
-**`<default>/`** — the default branch worktree (e.g. `main` or `master`). Kept as a clean reference. Used for diffing, reading docs, running comparisons. Never directly committed to.
28
28
-**`<N>-<slug>/`** — one worktree per issue in flight. Named by issue number and a short slug. Branch name matches the folder name.
> The [Checkout-GitHubRepo](https://github.com/MariusStorhaug/.dev/blob/main/.github/Checkout-GitHubRepo.ps1) script automates this for all repositories.
0 commit comments