Repository navigation
docs: document linear git history - #221
Conversation
936888d to
742676a
Compare
tt-a1i
left a comment
There was a problem hiding this comment.
Changes requested. CI is green on the reviewed head, but the guide currently contains a reproducible destructive update path and policy/configuration inconsistencies. Please also add a discoverable contributor entry point (for example, a root CONTRIBUTING.md or links from README.md/docs/README.md plus a category index); otherwise the stated workflow remains difficult for contributors to find. Current repository settings still allow merge commits and main does not require linear history, so this documentation-only PR should not imply that enforcement is already active.
tt-a1i
left a comment
There was a problem hiding this comment.
入口可发现性、当前 GitHub 设置说明、Squash/Rebase 规则、显式 lease 和 ff-only 更新都已修好;但 pushed-branch 示例仍会把正常 rebase 后作者自己的旧提交当成协作者新增提交,导致文档推荐的标准流程无法继续。请按行级评论调整远端 tip 的捕获时序。git diff --check、bun run check 和远端两路 CI 均通过;PR 仍落后 main。
3aaf22a to
2dd6836
Compare
tt-a1i
left a comment
There was a problem hiding this comment.
Re-review on 2dd6836: the pushed-branch sequence now captures the exact remote tip before rebasing, compares it with the live remote tip after rewriting, and uses that pre-rebase SHA as the explicit lease. Normal rebase no longer misclassifies the author’s old commits, while concurrent remote updates still fail closed. The branch is current with main. Local bun run check passed; full suite passed with 941 Node and 30 Vitest tests. Remote Node 22.19 and Node 24 CI both passed.
* docs: document linear git history * docs: address linear history review * docs: fix rebased branch update sequence --------- Co-authored-by: tt-a1i <[email protected]> (cherry picked from commit 0ff3263)
Problem
The repository currently permits merge commits, so pull requests can add unnecessary branch topology to
main. Contributors and maintainers also lack one documented workflow for preparing and merging a linear pull request.Value
A shared fast-forward and linear-history policy makes the project log easier to inspect, bisect, and use for release tracking. It also gives maintainers an explicit default for removing intermediate development commits.
Approach
Add an English contribution guide that documents:
main;--force-with-lease;--match-head-commit; andThe guide explicitly does not propose rewriting already published history.
Validation
git diff --checkbun run check(passed; existing Effect warnings only)bun run test(Node 928/928, Vitest 30/30)Impact
Documentation only. No user-visible runtime behavior, model-visible context or tools, lifecycle behavior, persisted data, or compatibility changes.