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: .github/CONTRIBUTING.md
+24-1Lines changed: 24 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -41,11 +41,34 @@ Assigned issues left quiet for two weeks may be unassigned. Comment to pick one
41
41
42
42
## Pull requests
43
43
44
-
1. Branch off `main`.
44
+
1. Branch off `main`, or off the parent branch if this is one of a stack.
45
45
2. Title the pull request as a [Conventional Commit](https://www.conventionalcommits.org/). Pull requests are merged with a merge commit whose subject is the pull request title, so the title is what release-please reads. `lint-pr.yml` enforces this.
46
46
3. All CI checks must pass before merge (PHPCS, PHPStan, PHPUnit across PHP 7.4 + 8.3 plus a multisite run, Playwright).
47
47
4. Keep commits focused, one logical change per commit.
48
48
49
+
### Stacks
50
+
51
+
A change too large to review in one pass goes in as a stack: each pull request based on the previous one, so each diff is only what that step added. Split where the reviewer's question changes, not every N lines. Nothing beyond git and `gh` is needed.
52
+
53
+
```bash
54
+
git checkout -b feature/thing-schema main
55
+
# commit
56
+
git checkout -b feature/thing-write
57
+
```
58
+
59
+
Open each one against its parent, or its diff carries the parent's work too:
60
+
61
+
```bash
62
+
gh pr create --base main --head feature/thing-schema
Put the same numbered list of the whole stack at the top of every body, marking the current one, so a reviewer landing in the middle knows what it sits on.
67
+
68
+
When a lower pull request changes, rebase each branch above it in order and push with `--force-with-lease`, never plain `--force`.
69
+
70
+
Merge bottom-up, one at a time, each on its own green CI. GitHub retargets a child to `main` when its base is merged and deleted, so nothing needs re-pointing by hand.
71
+
49
72
## Getting credited
50
73
51
74
Props are tied to WordPress.org profiles, not GitHub accounts. Props-bot comments the running list on every pull request. Two things let it find you:
0 commit comments