Changesets · Branches · Tags · Compare
| Changeset | e8031b33dc5ad13f7b3bd87f71d995629203797748d7fe9d127eff351ca5305a |
|---|---|
| Author | WaylandYang <145302500+WaylandYang@users.noreply.github.com> · 2026-09-02 20:18 +08:00 |
| Committer | GitHub <noreply@github.com> · 2026-09-02 20:18 +08:00 |
| Parents | fe16bbb4f71a |
2 files changed
modified CONTRIBUTING.md +2 −0
| @@ -90,6 +90,8 @@ | ||
| 90 | 90 | |
| 91 | 91 | **Commit messages: one English sentence, stating the motivation.** No long body. Skim `git log` for the register. |
| 92 | 92 | |
| 93 | +**Every workflow declares its own `permissions:`.** The repository default is now read-and-write, because one workflow commits a generated chart. A workflow without a `permissions:` block inherits that default, so leaving it out silently hands write access to something that only needed to read. Declare the minimum the job actually needs — `contents: read` for anything that just builds or tests. | |
| 94 | + | |
| 93 | 95 | ## DCO: sign off every commit |
| 94 | 96 | |
| 95 | 97 | We use the [DCO](https://developercertificate.org/), not a CLA. You keep the copyright on your code; you are certifying that you have the right to submit it under Apache-2.0. |
modified CONTRIBUTING.zh-CN.md +2 −0
| @@ -90,6 +90,8 @@ | ||
| 90 | 90 | |
| 91 | 91 | **提交信息一句英文,说清动机。** 不写长 body。看一眼 `git log` 就知道调子。 |
| 92 | 92 | |
| 93 | +**每个 workflow 自己声明 `permissions:`。** 仓库默认现在是读写——有一个 workflow 要把生成的图提交回来。不写 `permissions:` 块的 workflow 会继承那个默认,于是一个只需要读的任务悄悄拿到了写权限。按这个任务实际需要的最小集写:只做构建或测试的,写 `contents: read`。 | |
| 94 | + | |
| 93 | 95 | ## DCO:每个提交要签 |
| 94 | 96 | |
| 95 | 97 | 我们用 [DCO](https://developercertificate.org/)(开发者原创声明),不用 CLA。你保留自己代码的著作权,只是声明你有权按 Apache-2.0 提交它。 |