Skip to content

Commit d6d3e3d

Browse files
authored
Merge pull request #32 from DDecoene/feature/31-contributing
Document contributor workflow for GitFlow release branches (#31)
2 parents 6be7ad5 + 99ad111 commit d6d3e3d

4 files changed

Lines changed: 92 additions & 6 deletions

File tree

‎.github/pull_request_template.md‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<!--
2+
Base branch: target the active release branch (release/vX.Y.Z), NOT main.
3+
See CONTRIBUTING.md. GitHub defaults the base to main — change it.
4+
-->
5+
6+
## Summary
7+
8+
<!-- What does this change and why? -->
9+
10+
Refs #<!-- issue number -->
11+
12+
## Checklist (Definition of Done)
13+
14+
- [ ] PR base is the active **`release/vX.Y.Z`** branch (not `main`)
15+
- [ ] `npm test` (Vitest) passes
16+
- [ ] `npx playwright test` passes — includes a Playwright e2e case for any user-facing command/feature
17+
- [ ] Docs updated as relevant: `README.md`, `CHANGELOG.md` (under the milestone heading), `CLAUDE.md`
18+
- [ ] Screenshots retaken if the UI changed
19+
- [ ] No `Co-Authored-By` / AI attribution in commits

‎CHANGELOG.md‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ Versions follow [Semantic Versioning](https://semver.org/) — minor bump per su
1010
## [1.1.0] — 2026-06-27 — Live multiuser data propagation
1111

1212
### Added
13+
- `CONTRIBUTING.md` rewritten for the GitFlow model: fork → branch off the active
14+
`release/vX.Y.Z` → PR against that release branch (not `main`), plus a Definition of
15+
Done section. Added a PR template and a README "Contributing" pointer. (#31)
1316
- `JOIN WITH <alias> TO <file> FOR <cond> [FIELDS <list>]` — materialize a combined
1417
snapshot table from two open work areas, computed by SQLite's join planner.
1518
Deviations from dBASE III (FOR required, `alias.field` dot syntax, SQL-predicate

‎CONTRIBUTING.md‎

Lines changed: 63 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,74 @@ See [CLAUDE.md](CLAUDE.md) for the full architecture overview and W3Script comma
2626
## Running tests
2727

2828
```bash
29-
npm test # Vitest — must be green before any PR
30-
npx playwright test # E2E — requires the dev server running on :5173/:3000
29+
npm test # Vitest — unit + integration; must be green before any PR
30+
npx playwright test # E2E — auto-starts the dev server via playwright.config.ts
3131
```
3232

33-
## Making changes
33+
## Branching workflow (important — read this)
34+
35+
WebBase-III uses **GitFlow with milestone-versioned release branches**, so the one
36+
thing that trips people up is the PR base: **you target the active release branch,
37+
not `main`.**
38+
39+
- `main` holds only released, tagged code — it's branch-protected and PRs against it
40+
can't be merged by contributors.
41+
- All work for a version integrates on that version's **`release/vX.Y.Z`** branch
42+
(one per GitHub milestone). A [milestone](https://github.com/DDecoene/WebBaseIII/milestones)
43+
maps 1:1 to its release branch — find the open milestone (e.g. `v1.1.0`) and that's
44+
your base branch (`release/v1.1.0`).
45+
46+
### Step by step
47+
48+
```bash
49+
# 1. Fork on GitHub, then clone your fork and add upstream
50+
git clone https://github.com/<you>/WebBaseIII.git
51+
cd WebBaseIII
52+
git remote add upstream https://github.com/DDecoene/WebBaseIII.git
53+
git fetch upstream
54+
55+
# 2. Branch off the CURRENT release branch (NOT main)
56+
git checkout -b feature/my-change upstream/release/v1.1.0
57+
58+
# 3. ...make changes + tests, commit...
59+
60+
# 4. Push to your fork
61+
git push -u origin feature/my-change
62+
```
63+
64+
Then open the PR on GitHub and **change the base branch from `main` to
65+
`release/vX.Y.Z`** (the base dropdown defaults to `main` — you must switch it).
66+
Reference the issue with `Refs #N` in the body. Because the PR merges into a
67+
non-default branch, `Closes #N` won't auto-close the issue; the maintainer closes it
68+
on merge.
69+
70+
To keep your branch current (we periodically merge `main` into open release
71+
branches): `git fetch upstream && git merge upstream/release/v1.1.0`.
3472

3573
1. Open an issue first for anything non-trivial, so we can discuss the approach.
36-
2. Fork, branch, and keep PRs focused — one feature or fix per PR.
74+
2. Keep PRs focused — one feature or fix per PR.
3775
3. Add or update tests for what you change. Bug fixes need a regression test.
38-
4. Run `npm test` and make sure it passes.
39-
5. Update docs that your change makes stale: `README.md` command tables, `CHANGELOG.md` (Added / Fixed / Changed), and `CLAUDE.md` if architecture changed.
76+
77+
## Definition of Done
78+
79+
Your PR is expected to meet the project's
80+
[Definition of Done](CLAUDE.md#definition-of-done). In short:
81+
82+
- **`npm test` and `npx playwright test` both pass.**
83+
- **Every user-facing command/feature ships with a Playwright e2e case** in the same
84+
PR — a REPL command needs a `tests/*.spec.ts` case that types it and asserts the
85+
rendered result. Unit coverage alone is not "done."
86+
- **CI gates the merge** — the `unit` and `e2e` jobs must be green on your PR. CI runs
87+
for fork PRs automatically; the suite needs no secrets.
88+
- **Docs reflect the change** — update `README.md` command tables / feature list,
89+
`CHANGELOG.md` (Added / Fixed / Changed under the milestone heading), and `CLAUDE.md`
90+
if architecture changed. Retake screenshots if the UI changed.
91+
92+
## Commit conventions
93+
94+
Use concise, conventional-commit-style messages matching the existing history
95+
(`feat(...)`, `fix(...)`, `test(...)`, `docs: ...`). **Do not add `Co-Authored-By`
96+
trailers or any AI/assistant attribution** — commits are authored solely by you.
4097

4198
## What to work on
4299

‎README.md‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,13 @@ and CSV `COPY TO`/`APPEND FROM`. CI runs both Vitest and Playwright on every PR.
414414

415415
---
416416

417+
## Contributing
418+
419+
Contributions are welcome! WebBase-III uses **GitFlow** — fork the repo and open your
420+
PR against the **active `release/vX.Y.Z` branch** (the open milestone), not `main`.
421+
See [CONTRIBUTING.md](CONTRIBUTING.md) for the full fork → release-branch workflow and
422+
the Definition of Done.
423+
417424
## Contributors
418425

419426
Huge thanks to everyone who has helped extend WebBase-III:

0 commit comments

Comments
 (0)